Design Idea: Sketcher 'Point' and TechDraw

Discussions about the development of the TechDraw workbench
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
rich61
Posts: 156
Joined: Sat Jul 20, 2019 9:56 am

Design Idea: Sketcher 'Point' and TechDraw

Post by rich61 »

If a 'Point' object is created in Sketcher, it does not appear in TechDraw.

Points are stored and retrieved in sketch, but I don't see the point illustrated in the 3D model image. In another thread I illustrated how I was able to use the SplitEdge function to create a point that show up in TechDraw without changing the shape of the part.

Of course SplitEdge creates a 'Point' or vertex object and connects the resulting two lines, which to stay intact need to also have a colinear (tangent) constraint applied. A 'Point' would be much better.

Is it possible to make the Point show up in TechDraw ? Is it easy ? Is this a worthwhile idea to others ?

A point constrained to a 'point of interest' in the Sketch, could serve as a good way to dimension a property in Techdraw.
User avatar
adrianinsaval
Veteran
Posts: 5553
Joined: Thu Apr 05, 2018 5:15 pm

Re: Design Idea: Sketcher 'Point' and TechDraw

Post by adrianinsaval »

sketcher points are created as construction geometry (and are therefore not shown in 3D) you can turn them into normal geometry with the toggle construction command and they will show up in 3d.
rich61
Posts: 156
Joined: Sat Jul 20, 2019 9:56 am

Re: Design Idea: Sketcher 'Point' and TechDraw

Post by rich61 »

Thanks, it worked, that shows my sketch point on the surface of my model. But it isn't available in TechDraw as far as I can see.

When in non-construction mode, if I make a circle it is red, and a real feature. When I place a point is automatically a construction feature?

If I make a line in non-construction mode, it is red. If I change that line to construction type, it is blue. Initially when placed, a point is red indicating it is a real object. When I toggle to construction mode, it is white, not blue, but then it appears in the model. Interesting behavior.

I was hoping that it would show up in TechDraw, but seems like it does not.

I wonder why it is not visible to TechDraw ?

How could I find it in the code base ? I should start learning how things are implemented. Maybe I could make an experimental change.
User avatar
Roy_043
Veteran
Posts: 8578
Joined: Thu Dec 27, 2018 12:28 pm

Re: Design Idea: Sketcher 'Point' and TechDraw

Post by Roy_043 »

rich61 wrote: Wed Dec 28, 2022 12:35 pm If I make a line in non-construction mode, it is red. If I change that line to construction type, it is blue. Initially when placed, a point is red indicating it is a real object. When I toggle to construction mode, it is white, not blue, but then it appears in the model. Interesting behavior.
You misunderstand. With the default colors, when the color of a point (Sketcher_CreatePoint) is red in the 3D view, it is construction geometry. So you are not toggling 'to' but 'from' construction mode.
User avatar
adrianinsaval
Veteran
Posts: 5553
Joined: Thu Apr 05, 2018 5:15 pm

Re: Design Idea: Sketcher 'Point' and TechDraw

Post by adrianinsaval »

rich61 wrote: Wed Dec 28, 2022 12:35 pm I was hoping that it would show up in TechDraw, but seems like it does not.

I wonder why it is not visible to TechDraw ?
Probably techdraw only imports edges, the code is likely somewhere in here: https://github.com/FreeCAD/FreeCAD/tree ... chDraw/App
chrisb
Veteran
Posts: 54293
Joined: Tue Mar 17, 2015 9:14 am

Re: Design Idea: Sketcher 'Point' and TechDraw

Post by chrisb »

adrianinsaval wrote: Wed Dec 28, 2022 12:08 pm and they will show up in 3d.
They show up in 3D view but not in TechDraw. This was discussed before and I'm pretty sure that there exists a feature request.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
rich61
Posts: 156
Joined: Sat Jul 20, 2019 9:56 am

Re: Design Idea: Sketcher 'Point' and TechDraw

Post by rich61 »

I thank you Adrian and Roy and Chrisb.
chrisb
Veteran
Posts: 54293
Joined: Tue Mar 17, 2015 9:14 am

Re: Design Idea: Sketcher 'Point' and TechDraw

Post by chrisb »

There is no feature request yet; see https://forum.freecadweb.org/viewtopic. ... 35&t=65910 .
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
rich61
Posts: 156
Joined: Sat Jul 20, 2019 9:56 am

Re: Design Idea: Sketcher 'Point' and TechDraw

Post by rich61 »

Thanks for that link, Chrisb. I think I understand that first sentence. There are 3rd party softwares that can not be touched, so some limitations. Does the second sentence refer to some FreeCAD mechanism, "send through the detour" ?
Points don't make it through the projection process. There is a detour for Part and Draft points, but it won't pick up a Sketcher point because it isn't a DocumentObject.

Will have to parse the sketch's Geometry property for points and send them through the detour.
My application/user level workaround is to use a tiny circle if within the part boundaries. However if you need a point on an edge, you can make a circle then trim it to a tiny arc so that I can use the center point in techdraw, splitedge and collinear constraint is another way. If the diameter/radius is small enough, it looks OK as drawing document.

Then I wonder, if a similar workaround could be implemented deeper in the system, so that a circle, splitline, arc, might work since they are DocumentObjects, but because of a specific diameter or threshold dimension could be interpreted as a point. Its probably too messy and has some negative consequences I'm not thinking of.
chrisb
Veteran
Posts: 54293
Joined: Tue Mar 17, 2015 9:14 am

Re: Design Idea: Sketcher 'Point' and TechDraw

Post by chrisb »

Moved to TechDraw forum. Perhaps has @wandererfan some new ideas.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
Post Reply