Showing the not constrained elements of a sketch in Sketcher WB

Have some feature requests, feedback, cool stuff to share, or want to know where FreeCAD is going? This is the place.
Forum rules
Be nice to others! Read the FreeCAD code of conduct!
dxp.dev
Posts: 85
Joined: Tue Dec 11, 2018 12:57 pm

Showing the not constrained elements of a sketch in Sketcher WB

Postby dxp.dev » Sat Jan 19, 2019 2:56 pm

Hi,

I was wondering if it was possible to add a feature in the Sketcher WB to automatically pointing/showing where a Sketch is not constrained ?

As when it is completely constrained it turns green, could we (should we?) add an intermediary display where what is already constrained is of a specific color and what is not still in white ? Or on the contrary showing where there are still degrees of freedom in a particular color ?

What do you think of that ? I know that the workaround is to randomly grab and try to move elements of the sketch, but for complex sketches it can take some time.
GeneFC
Posts: 1025
Joined: Sat Mar 19, 2016 3:36 pm
Location: Punta Gorda, FL

Re: Showing the not constrained elements of a sketch in Sketcher WB

Postby GeneFC » Sat Jan 19, 2019 4:20 pm

Even without considering any programming difficulties this is not really possible, or at least not possible in a useful manner.

As an example, draw a rectangle using the standard icon in the toolbar, and set lengths for the horizontal and vertical lines.

The solver message will say right at the top, "Under-constrained sketch with 2 degrees of freedom".

However, *every* element in the sketch is still movable. It is not possible to say that *any* element, vertex or line, is fully constrained.

Then fix any single vertex to a position and suddenly every element is fully constrained.

This request has been made several times in the past, and it would be great if it was possible. However, it is logically impossible.

Gene
chrisb
Posts: 18076
Joined: Tue Mar 17, 2015 9:14 am

Re: Showing the not constrained elements of a sketch in Sketcher WB

Postby chrisb » Sat Jan 19, 2019 5:47 pm

In 0.18 the Sketcher makes proposals which elements to constrain further. As Gene has explained there are usually different possibilities to constrain a sketch. The developer of Sketcher/Solver (Abdullah) has done more than I ever had expected. I think it's not possible to do more.
usertogo
Posts: 24
Joined: Wed Dec 26, 2018 1:28 pm

Re: Showing the not constrained elements of a sketch in Sketcher WB

Postby usertogo » Sun Jan 20, 2019 11:37 am

I second that opinion that colors should be used to indicate the level of constraint...
However I also would like to suggest to #F__k constraints! Why be so restrictive all the time?
I would suggest to implement an option to not care for constraints! Good enough if the sketch is stable in a given moment!
If somebody chose to work with something that is not fully constraint, maybe his design will go all bezerk some day, but who cares it happens anyways for so many other reasons...
Also the inability to recognize, highlight, and offer to reference any edges, planes origin points appears arbitrary, and should never been disabled inside a sketch (or in the worst case as a non default option! Default should be to be able to select any geometry that can be easily deducted to the normal of the plane that is being worked on, and in case somebody initiates a reference to such geometry give them a dialog that says this will require to reference 'external' geometry 'are you sure you want to proceed'.
If there is any ambiguity on which plane, object, body etc. a feature should be applied to this relation should be an option that should be modifiable. I know this requires to have a full parametric design tree in which the sequence of features makes a difference. The capacity to roll back and reorder features would require some discipline from the designer, but it will enable things that even very expensive design packages may not fully support!
For example I am struggling because I haven't even figured out how to reference to such a universal concept such as the origin point (or 'XZZ zero planes'), which should be possible by default on any sketch plane.

I am proposing to be warning but not restricting - this is the essence of enabling creativity!
Restriction require code too!
I would like a streamlined interface where where mouse over highlights anything without restrictions,
Right click asks the highlighted or selected object what methods it supports and which data it can deliver
If for example a highlighted surface is flat it could deliver a mathematical plane this should be offered to intersect with any other plane (if you are in a sketch offer to add a construction line based on this intersection!
If it's always straightforward enabled by default, disable if you must - you will be surprised how fast we get to a super powerful and quick to learn interface!
chrisb
Posts: 18076
Joined: Tue Mar 17, 2015 9:14 am

Re: Showing the not constrained elements of a sketch in Sketcher WB

Postby chrisb » Sun Jan 20, 2019 3:33 pm

usertogo wrote:
Sun Jan 20, 2019 11:37 am
I second that opinion that colors should be used to indicate the level of constraint...
However I also would like to suggest to #F__k constraints! Why be so restrictive all the time?
I would suggest to implement an option to not care for constraints! Good enough if the sketch is stable in a given moment!
If somebody chose to work with something that is not fully constraint, maybe his design will go all bezerk some day, but who cares it happens anyways for so many other reasons...
Do you know what you are talking about? It's been there for years. Switch autoconstraints off, create your sketch by adding the elements and that's it. Or use draft workbench where you haven't any constraints at all.

My personal view: Constraints are a blessing not a penalty!


Also the inability to recognize, highlight, and offer to reference any edges, planes origin points appears arbitrary, and should never been disabled inside a sketch
it is neither arbitrary nor disabled. You cannot reference arbitrary elements in the world, and that serves reasonable purposes. Please make yourself familiar with these concepts. The wiki and this forum hold lots of information.
GeneFC
Posts: 1025
Joined: Sat Mar 19, 2016 3:36 pm
Location: Punta Gorda, FL

Re: Showing the not constrained elements of a sketch in Sketcher WB

Postby GeneFC » Sun Jan 20, 2019 5:05 pm

usertogo wrote:
Sun Jan 20, 2019 11:37 am
If it's always straightforward enabled by default, disable if you must - you will be surprised how fast we get to a super powerful and quick to learn interface!
Do you have a github account? I am sure your pull requests would be welcome by the reviewers. :lol:

Gene
User avatar
NormandC
Posts: 18534
Joined: Sat Feb 06, 2010 9:52 pm
Location: Québec, Canada

Re: Showing the not constrained elements of a sketch in Sketcher WB

Postby NormandC » Sun Jan 20, 2019 6:19 pm

@usertogo

If you don't want to use constraints, just don't use them. :roll:

The truth is that parametric modeling programs were not really designed for concept design. Their purpose is to build models ready for manufacturing. They are poorly suited to quickly explore designs and ideas.

As for the rest of your ideas, sliptonic put it best a few months ago:

sliptonic wrote:
Fri Sep 14, 2018 8:19 pm
The developers here are all volunteers, working on whatever they want to work on. Mostly they want a great application that meets their own needs and they're willing to cooperate to get it and everybody else benfits from it.

But those developers are often put in a no-win situation. If they spend time polishing existing features, they're attacked for being slow to introduce new stuff. If they introduce lots of new stuff, people like you come by and blast them for not polishing it. They do what any sane person would do who isn't being paid for their time and effort. They listen to those that are helping out.

You're fundamentally misunderstanding the nature of open-source software. Much of the code-base, including many of the very features you are 'complaining in a way that annoys people' about, was written by developers that have long since left the project. If someone doesn't step in and pick it up, it won't get fixed. Either you can do that work and won't, or you can't do it at all. Either way, complaining about it doesn't 'prod the bears' to do it for you. It just pisses them off.
usertogo
Posts: 24
Joined: Wed Dec 26, 2018 1:28 pm

Re: Showing the not constrained elements of a sketch in Sketcher WB

Postby usertogo » Sun Jan 20, 2019 11:51 pm

GeneFC wrote:
Sun Jan 20, 2019 5:05 pm
usertogo wrote:
Sun Jan 20, 2019 11:37 am
If it's always straightforward enabled by default, disable if you must - you will be surprised how fast we get to a super powerful and quick to learn interface!
Do you have a github account? I am sure your pull requests would be welcome by the reviewers. :lol:

Gene
Sure do, even have released a tiny open source Arduino Code, but honestly I have no idea why anybody would care if I made such a request without being able to add some code to it?
dxp.dev
Posts: 85
Joined: Tue Dec 11, 2018 12:57 pm

Re: Showing the not constrained elements of a sketch in Sketcher WB

Postby dxp.dev » Mon Jan 21, 2019 5:03 pm

chrisb wrote:
Sat Jan 19, 2019 5:47 pm
In 0.18 the Sketcher makes proposals which elements to constrain further. As Gene has explained there are usually different possibilities to constrain a sketch. The developer of Sketcher/Solver (Abdullah) has done more than I ever had expected. I think it's not possible to do more.
GeneFC wrote:
Sat Jan 19, 2019 4:20 pm
Even without considering any programming difficulties this is not really possible, or at least not possible in a useful manner.

As an example, draw a rectangle using the standard icon in the toolbar, and set lengths for the horizontal and vertical lines.

The solver message will say right at the top, "Under-constrained sketch with 2 degrees of freedom".

However, *every* element in the sketch is still movable. It is not possible to say that *any* element, vertex or line, is fully constrained.

Then fix any single vertex to a position and suddenly every element is fully constrained.

This request has been made several times in the past, and it would be great if it was possible. However, it is logically impossible.

Gene
Ok, thanks