Sketcher: Bezier curves

Here's the place for discussion related to coding in FreeCAD, C++ or Python. Design, interfaces and structures.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
abdullah
Veteran
Posts: 4935
Joined: Sun May 04, 2014 3:16 pm
Contact:

Re: Sketcher: Bezier curves

Post by abdullah »

wmayer wrote:All good now. Thanks for your quick fixes and awesome contributions!
You are welcome. It is a privilege to work with you.
wmayer
Founder
Posts: 20243
Joined: Thu Feb 19, 2009 10:32 am
Contact:

Re: Sketcher: Bezier curves

Post by wmayer »

A new coverity scan found this issue in int Sketch::addConstraint(const Constraint *constraint):

Code: Select all

case BSplineControlPoint:
    rtn = addInternalAlignmentBSplineControlPoint(constraint->First,constraint->Second, constraint->InternalAlignmentIndex);
case BSplineKnotPoint:
    rtn = addInternalAlignmentKnotPoint(constraint->First,constraint->Second, constraint->InternalAlignmentIndex);
default:
    break;
Is it intended to omit the break after BSplineControlPoint and BSplineKnotPoint?
abdullah
Veteran
Posts: 4935
Joined: Sun May 04, 2014 3:16 pm
Contact:

Re: Sketcher: Bezier curves

Post by abdullah »

wmayer wrote:Is it intended to omit the break after BSplineControlPoint and BSplineKnotPoint?
Not at all. I wonder how things actually work sometimes...

https://github.com/FreeCAD/FreeCAD/pull/688
User avatar
microelly2
Veteran
Posts: 4688
Joined: Tue Nov 12, 2013 4:06 pm
Contact:

Re: Sketcher: Bezier curves

Post by microelly2 »

There is one big feature to improve usability I want to request:
Hide/unhide the blue constraints
I use the blue constraints as driver for more complex sketches
and for a "free" curve design the sketcher can be used but the data should be hidden.

https://www.youtube.com/watch?v=J4kD1LLP3uU

Thanks in advance
abdullah
Veteran
Posts: 4935
Joined: Sun May 04, 2014 3:16 pm
Contact:

Re: Sketcher: Bezier curves

Post by abdullah »

microelly2 wrote:There is one big feature to improve usability I want to request:
Hide/unhide the blue constraints
I use the blue constraints as driver for more complex sketches
and for a "free" curve design the sketcher can be used but the data should be hidden.

https://www.youtube.com/watch?v=J4kD1LLP3uU

Thanks in advance
So you use driven constraints as reference constraints for bspline parameter computation. Nice!!

In my list of sketch usability improvements there is inter alia:
1. hiding construction geometry from the inventor view
2. allowing to filter in the Elements Widget by construction yes, construction no, only construction (not clear yet how I want to put this in the UI)
3. hiding internal alignment constraints from the Constraint's Widget

so I add to it:
4. hiding driven constraints in the inventor view.

Feel free to speak up if you see any other usability improvement ;)
abdullah
Veteran
Posts: 4935
Joined: Sun May 04, 2014 3:16 pm
Contact:

Re: Sketcher: Bezier curves

Post by abdullah »

microelly2 wrote:There is one big feature to improve usability I want to request:
Hide/unhide the blue constraints
I use the blue constraints as driver for more complex sketches
and for a "free" curve design the sketcher can be used but the data should be hidden.

https://www.youtube.com/watch?v=J4kD1LLP3uU

Thanks in advance
https://forum.freecadweb.org/viewtopic. ... 04#p170204

Pull Request:
https://github.com/FreeCAD/FreeCAD/pull/696
User avatar
NormandC
Veteran
Posts: 18587
Joined: Sat Feb 06, 2010 9:52 pm
Location: Québec, Canada

Re: Sketcher: Bezier curves

Post by NormandC »

abdullah, you are on fire! :D
abdullah
Veteran
Posts: 4935
Joined: Sun May 04, 2014 3:16 pm
Contact:

Re: Sketcher: Bezier curves

Post by abdullah »

It is good to have time to code. It feels good!
User avatar
Kunda1
Veteran
Posts: 13434
Joined: Thu Jan 05, 2017 9:03 pm

Re: Sketcher: Bezier curves

Post by Kunda1 »

Soft segway: Just a little historical context: The history of Bézier curves
Alone you go faster. Together we go farther
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
User avatar
microelly2
Veteran
Posts: 4688
Joined: Tue Nov 12, 2013 4:06 pm
Contact:

Re: Sketcher: Bezier curves

Post by microelly2 »

Kunda1 wrote:Soft segway: Just a little historical context: The history of Bézier curves
nice paper with a lot of interesting things.
Post Reply