keithsloan52 wrote: ↑
Wed Jan 13, 2021 2:38 pm
Aimed at re-engineering existing models i.e imported STEP and OpenSCAD models.
( Renamed from Face2Sketch ) https://github.com/KeithSloan/toSketch
Provides the following facilities
- Face to Sketch : Select a planar face and then creates a new sketch
- Section Plane to Sketch : Select a Plane which will then be used to section Objects and create a new sketch
Interested in feedback and any other suggestions to help with re-engineering models coming from external sources.
Just waiting for icon from @jmaustin
I took a look at the Python code. I see you use the draft WB conversion routines with autoconstraints set on.
I do not know well those routines. What I wanted to say is that the Sketcher has some autoconstraining functionality that might be useful after applying the draft to sketcher conversion. Maybe it is useless to your use case. Just in case.
This is are the Python functions (not only the autoconstraint one, but then there are others to detect missing horizontal, vertical,)
https://github.com/FreeCAD/FreeCAD/blob ... .cpp#L1497
The actual c++ functions are here (in case you want to take a look to the insides):
https://github.com/FreeCAD/FreeCAD/blob ... s.cpp#L143
And probably the best addition to all them. Somebody that knows how to use them:
The ping is just to make you aware of this thread, in case Keith has questions about how you use these from Python
I can look into the c++ code, but I no longer remember by heart of what they offer...