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!
domad
Veteran
Posts: 2094
Joined: Mon Jun 22, 2020 12:16 pm

Re: Design Idea: Sketcher 'Point' and TechDraw

Post by domad »

Greetings to the Community!
...waiting for @wandererfan to find the solution to make "Sketcher" points visible in TechDraw views, you can work around it with some tricks or use Draft-points.
The two animated gifs show how to do it using "Sketcher" or "Draft".
Draft-points used as references in TechDraw can be grouped in a "Group Folder" and then in the link-source parameter of the TechDraw view add it.
Attachments
point_sketch_in_TechDraw.gif
point_sketch_in_TechDraw.gif (556.44 KiB) Viewed 1014 times
point_sketch-Draft_in_TechDraw.gif
point_sketch-Draft_in_TechDraw.gif (919.18 KiB) Viewed 1014 times
User avatar
wandererfan
Veteran
Posts: 6321
Joined: Tue Nov 06, 2012 5:42 pm
Contact:

Re: Design Idea: Sketcher 'Point' and TechDraw

Post by wandererfan »

domad wrote: Wed Dec 28, 2022 6:39 pm Draft-points used as references in TechDraw can be grouped in a "Group Folder" and then in the link-source parameter of the TechDraw view add it.
This works with Part::Vertex also.
user1234
Veteran
Posts: 3512
Joined: Mon Jul 11, 2016 5:08 pm

Re: Design Idea: Sketcher 'Point' and TechDraw

Post by user1234 »

A point can not deviated from 3D, see https://dev.opencascade.org/doc/overvie ... _modalg_10, restrictions.

Greetings
user1234
User avatar
wandererfan
Veteran
Posts: 6321
Joined: Tue Nov 06, 2012 5:42 pm
Contact:

Re: Design Idea: Sketcher 'Point' and TechDraw

Post by wandererfan »

chrisb wrote: Wed Dec 28, 2022 4:51 pm Perhaps has @wandererfan some new ideas.
Free points in a sketch do not appear in 3d and aren't included in the sketch's "shape". AFAICT, only points that are part of an edge are available. Since TechDraw works with shapes, the free points are not show in TechDraw either.

Free points are available in a sketch's Geometry property, so we could make an "import sketch geometry" command. This could provide construction geometry too, as construction geometry is available in Geometry (but not in the shape).

If we want to pick and choose which pieces of the sketch geometry to import (ex I only want 1 free point of the 10 in the sketch), it gets more complicated as we would run into TNP with the sketch+subelement references.

To summarize, if you are only interested in the edges in a sketch, then just include the sketch in the Source property. If you want to see free points, construction geometry or external geometry, we need a new command, some preferences and a way to save the import info.
User avatar
wandererfan
Veteran
Posts: 6321
Joined: Tue Nov 06, 2012 5:42 pm
Contact:

Re: Design Idea: Sketcher 'Point' and TechDraw

Post by wandererfan »

user1234 wrote: Wed Dec 28, 2022 7:08 pm A point can not deviated from 3D, see https://dev.opencascade.org/doc/overvie ... _modalg_10, restrictions.
But there is special handling in place for Draft.Point and Part.Vertex to pass them around the HLR process.
user1234
Veteran
Posts: 3512
Joined: Mon Jul 11, 2016 5:08 pm

Re: Design Idea: Sketcher 'Point' and TechDraw

Post by user1234 »

wandererfan wrote: Wed Dec 28, 2022 7:24 pm But there is special handling in place for Draft.Point and Part.Vertex to pass them around the HLR process.
Sneaky. Hopefully you will not be thrown form OCCT in jail for that (it is a joke).

Greetings
user1234
chrisb
Veteran
Posts: 54213
Joined: Tue Mar 17, 2015 9:14 am

Re: Design Idea: Sketcher 'Point' and TechDraw

Post by chrisb »

If Draft points can be shown in TechDraw, then this is a workaround for including a Sketcher point:
- Create a sketch with a point as real geometry
- Create a point in Draft
- Attach it to the sketch's point
- Include sketch plus point in a single view in TechDraw.

Alas, I have the serious issue that I cannot include a Point at all (file Attached, View is a rectangle plus point, View001 is only a point).
Attachments
pointsInTechDraw_cb.FCStd
(6.84 KiB) Downloaded 29 times
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
domad
Veteran
Posts: 2094
Joined: Mon Jun 22, 2020 12:16 pm

Re: Design Idea: Sketcher 'Point' and TechDraw

Post by domad »

chrisb wrote: Wed Dec 28, 2022 8:12 pm ....
Greetings to the Community!
...no problem for me

Code: Select all

OS: Linux Mint 20.3 (X-Cinnamon/cinnamon)
Word size of FreeCAD: 64-bit
Version: 0.21.0.31432 (Git) AppImage
Build type: Release
Branch: master
Hash: 63a2855751d638bf27ed969dc60654bda2b54baf
Python 3.10.8, Qt 5.15.4, Coin 4.0.0, Vtk 9.1.0, OCC 7.6.3
Local: Local
Attachments
pointsInTechDraw_cb-2.FCStd
(7.85 KiB) Downloaded 30 times
pointsInTechDraw_cb-2.png
pointsInTechDraw_cb-2.png (125.57 KiB) Viewed 887 times
rich61
Posts: 156
Joined: Sat Jul 20, 2019 9:56 am

Re: Design Idea: Sketcher 'Point' and TechDraw

Post by rich61 »

Thanks for all those ideas, I'll try them out.


I propose a new point, a TechDrawReferencePoint, or ReferencePoint for short.

Please point out any problems this idea would cause.

On the sketch menu, the point tool would be drop down like Sketch Fillet and Constraint-Preserving Fillet, so there would be the existing Point and a new drop down selection, Reference Point.

There are two cases:
1. Reference Point inside the sketch not touching any line and not inside a feature to become a pocket etc.
2. Reference Point on a line

Case 1:
The Reference Point is implemented as an infinitesimal diameter circle, which I'll call a Reference Point. Actually it is a real point (almost) that extrudes. The existing Point does not extrude to a line and in strict definition, isn't a real 3D point.
  • Tool Creates Infinitesimal Circle with fixed diameter.
In preferences, it might be necessary to enable or disable this feature, when the model is used to create drawings enable it, 3D printer user might not want it, nor people making a CNC path. Maybe for InJet printers they ignore features below the printer resolution, I don't know.

In Preferences, it might be necessary to define Infinitesimal, the smallest diameter used to create a circle that is newly defined as a Reference Point. There would be a real defined number for the radius so it can be identified as a Reference Point.

Of course, since this is actually a circle, there is probably no coding required in TechDraw. Maybe prohibit using the diameter dimension tool. As far as Sketch goes, I and others use this idea as a workaround, and it works. It looks like a dimensionable vertex in TechDraw.

Case 2: Reference Point on a Line
There are 2 ways to implement Case 2, Trim-Circle or Split-Edge

To create a Reference Point on a line, you can not use a complete circle. As a work around I do use a very small circle, then I trim the outside half of the circle such that the remaining circle radius cuts into the part. And of course I trim that part of the line across the circle. This gives TechDraw a centerpoint and again, looks like a dimensionable vertex.
  • Tool Creates Infinitesimal Circle (or arc) with fixed diameter.
    Tool Trim outside half of circle ( unless arc)
    Tool Trims line across circle or arc
If the new Reference Point is on a line, the circle center is located by constraints in Sketcher, the circle is properly trimmed, and then the line across the diameter of the circle is trimmed, all automatically by the Reference Point Tool.

The other existing function that might be used is 'Split Edge'. I have to remind myself sometimes, split edge is not a point, but when you use it, it gives the appearance of placing a point on the line. Actually, it is creating two lines from one and joining them. This creates a danger or inadvertently moving the lines. So the Reference Point tool must also apply the Tangent (collinear) Constraint to the joined lines. Now again, you have created what will be a dimensionable vertex in TechDraw.
  • Tool creates Split-Edge
    Tool applies Tangent/Collinear constraint
There are some additional considerations, for example if you create a Reference Point as Case 1, then you use a constraint to move that Reference Point to be on a line. Sketcher must convert the Reference Point from Type 1 to Type 2.

The Trim-Circle implementation is probably more disruptive to geometry than the Split-Edge implementation.

The idea is 90% definition, 10% coding. And no coding at all in TechDraw I think, although TechDraw could easily identify a Reference Point object by the Infinitesimal Diameter Parameter defined in Preferences. So if within TechDraw, it is useful to highlight or use the identity of it, that is possible also.

Its really just automating one of the workarounds I use, but who cares ? Just like Split-Edge gives me the impression that I'm placing a point on a line, this will simply be creating and locating a Reference Point with a click or constraint. And also, it is borrowing existing features of FreeCAD, but they are at such a tiny dimension that they approximate a point anyway.

So, shoot down the concept now. Why is it bad ? :)
domad
Veteran
Posts: 2094
Joined: Mon Jun 22, 2020 12:16 pm

Re: Design Idea: Sketcher 'Point' and TechDraw

Post by domad »

rich61 wrote: Thu Dec 29, 2022 9:29 am ....
Greetings to the Community!
It's not a bad idea to make Sketcher points visible and active in TechDraw views, far from it!
The methods you suggested have been discussed in the past, maybe you didn't read the reply to your topic in the dedicated forum "Help on using FreeCAD": https://forum.freecad.org/viewtopic.php ... 48#p649998, I think that if until now it hasn't been implemented it is probably to avoid exposing TechDraw to a further extension of the problems deriving from the "Topological naming problem".
Post Reply