[testing/user input] Blocked Constraint

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:

[testing/user input] Blocked Constraint

Post by abdullah »

Hi!

I am working on a new constraint codenamed "Blocked Constraint", which just freezes a sketcher edge in place without the need of any constraint. I am thinking of these use cases (many more may arise):

- Constraining certain shapes without bloating the UI (e.g. BSplines).

- Temporarily enabling to block certain geometry while applying constraints to prevent them from moving.

Teaser (fully constraining this sketch with just two tangent and two dimensional constraints):
BlockedConstraint.png
BlockedConstraint.png (44.66 KiB) Viewed 5909 times
Last edited by abdullah on Thu Dec 21, 2017 9:23 am, edited 1 time in total.
User avatar
microelly2
Veteran
Posts: 4688
Joined: Tue Nov 12, 2013 4:06 pm
Contact:

Re: [work in progress] Blocked Constraint

Post by microelly2 »

+1
I'm sure this will simplify the workflow to get "intuitive stable" sketch designs.
abdullah
Veteran
Posts: 4935
Joined: Sun May 04, 2014 3:16 pm
Contact:

Re: [work in progress] Blocked Constraint

Post by abdullah »

and there you see... a new use case in 4 minutes... ;)
chrisb
Veteran
Posts: 53930
Joined: Tue Mar 17, 2015 9:14 am

Re: [work in progress] Blocked Constraint

Post by chrisb »

I have regularly simulated this to keep sketches from jumping during the constraining process: I used to fix certain points with horizontal and vertical distances. If it's more than one point it's tedious and spoils the view.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
abdullah
Veteran
Posts: 4935
Joined: Sun May 04, 2014 3:16 pm
Contact:

Re: [work in progress] Blocked Constraint

Post by abdullah »

I start to like this feature. However, I will not be able to test it properly much. For that I would ask for volunteers to check this branch:

https://github.com/abdullahtahiriyo/Fre ... constraint

Known issues:
- The icons are [insert bad word here].
- The icons may not display at a reasonable location, or not at all (bspline)

What does it provide:
- Seamless blocking of a geometry element. Including any complex geometry element containing internal alignment geometry (ellipse, bspline,...)
- Seamless redundant/conflict constraint avoidance (so if you block something that is almost fully constrained, it will not complain that the constraints that where there are redundant/conflicting with the newly added "Blocked Constraint").

Do you need a teaser?
BlockedConstraint2.gif
BlockedConstraint2.gif (791.12 KiB) Viewed 5796 times
Edit: Yes, I am in a rush, so the gif is a little bit...rushed...
User avatar
Kunda1
Veteran
Posts: 13434
Joined: Thu Jan 05, 2017 9:03 pm

Re: [testing/user input] Blocked Constraint

Post by Kunda1 »

Joel_graff wrote:ping
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
Kunda1
Veteran
Posts: 13434
Joined: Thu Jan 05, 2017 9:03 pm

Re: [work in progress] Blocked Constraint

Post by Kunda1 »

abdullah wrote: Thu Dec 21, 2017 9:22 am Known issues:
- The icons are [insert bad word here].
- The icons may not display at a reasonable location, or not at all (bspline)
@abdullah Awesome. Thanks for the teaser! What do you think the icons should look like...got any ideas?
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
Joel_graff
Veteran
Posts: 1949
Joined: Fri Apr 28, 2017 4:23 pm
Contact:

Re: [testing/user input] Blocked Constraint

Post by Joel_graff »

This looks useful. :)

It certainly addresses an issue in the Transpiration workflow, though I'm starting to see how to do it without this sort of feature. But i imagineit would make things simpler
FreeCAD Trails workbench for transportation engineering: https://www.github.com/joelgraff/freecad.trails

pivy_trackers 2D coin3D library: https://www.github.com/joelgraff/pivy_trackers
User avatar
DeepSOIC
Veteran
Posts: 7896
Joined: Fri Aug 29, 2014 12:45 am
Location: used to be Saint-Petersburg, Russia

Re: [testing/user input] Blocked Constraint

Post by DeepSOIC »

Nice feature, can't remember how many times I wanted it :D
triplus
Veteran
Posts: 9471
Joined: Mon Dec 12, 2011 4:45 pm

Re: [testing/user input] Blocked Constraint

Post by triplus »

Nice!
Post Reply