Discussion topic for more easily enable / disable BOPCheck in Check Geometry
Forum rules
Be nice to others! Read the FreeCAD code of conduct!
Be nice to others! Read the FreeCAD code of conduct!
Discussion topic for more easily enable / disable BOPCheck in Check Geometry
Edit: filed as issue #4034.
In another topic, TheMarkster wrote that he had written a macro to easily enable / disable BOPCheck. Several regulars agreed that it would be handy to enhance the macro and provide a button or tickbox in the Check Geometry widget to easily toggle BOPCheck on and off instead of the existing Tools > Edit Parameters route. So, before I put in a ticket I'm opening this discussion thread.
The BOPCheck discussion I mentioned starts here:
https://forum.freecadweb.org/viewtopic. ... 10#p316228
In another topic, TheMarkster wrote that he had written a macro to easily enable / disable BOPCheck. Several regulars agreed that it would be handy to enhance the macro and provide a button or tickbox in the Check Geometry widget to easily toggle BOPCheck on and off instead of the existing Tools > Edit Parameters route. So, before I put in a ticket I'm opening this discussion thread.
The BOPCheck discussion I mentioned starts here:
https://forum.freecadweb.org/viewtopic. ... 10#p316228
Last edited by bejant on Mon Jun 24, 2019 10:31 pm, edited 1 time in total.
Re: Discussion topic for more easily enable / disable BOPCheck in Check Geometry
Sure it would be a nice idea.
Technically speaking I won't say "provide a button or tickbox in the Check Geometry widget to easily toggle BOPCheck on and off instead of the existing" but "provide a checkbox in the Check Geometry widget that will bind to the parameter value currently used".
So it's easier and less risky to code, and the old way still works. 
Technically speaking I won't say "provide a button or tickbox in the Check Geometry widget to easily toggle BOPCheck on and off instead of the existing" but "provide a checkbox in the Check Geometry widget that will bind to the parameter value currently used".


Re: Discussion topic for more easily enable / disable BOPCheck in Check Geometry
Actually ATM there is no HMI in the task panel when running "Check Geometry". Only result is displayed. Maybe a message box at check launching time asking "Do you want to also perform the BOPCheck ? Yes/No" would be enough ?
-
- Veteran
- Posts: 4569
- Joined: Thu Apr 05, 2018 1:53 am
Re: Discussion topic for more easily enable / disable BOPCheck in Check Geometry
Edit: https://github.com/FreeCAD/FreeCAD/pull/2291
How about a new "settings" panel in the task dialog? Currently it would only contain a checkbox to toggle RunBOPCheck parameter, but perhaps other settings could be added in the future. Open Cascade allows quite a few parameters to the bop check operations, which we currently set all to true (where the currently installed library supports them) in order to run all the tests. This from the source code:
How about a new "settings" panel in the task dialog? Currently it would only contain a checkbox to toggle RunBOPCheck parameter, but perhaps other settings could be added in the future. Open Cascade allows quite a few parameters to the bop check operations, which we currently set all to true (where the currently installed library supports them) in order to run all the tests. This from the source code:
Code: Select all
//all settings are false by default. so only turn on what we want.
BOPCheck.ArgumentTypeMode() = true;
BOPCheck.SelfInterMode() = true;
BOPCheck.SmallEdgeMode() = true;
BOPCheck.RebuildFaceMode() = true;
#if OCC_VERSION_HEX >= 0x060700
BOPCheck.ContinuityMode() = true;
#endif
#if OCC_VERSION_HEX >= 0x060900
BOPCheck.SetParallelMode(true); //this doesn't help for speed right now(occt 6.9.1).
BOPCheck.SetRunParallel(true); //performance boost, use all available cores
BOPCheck.TangentMode() = true; //these 4 new tests add about 5% processing time.
BOPCheck.MergeVertexMode() = true;
BOPCheck.CurveOnSurfaceMode() = true;
BOPCheck.MergeEdgeMode() = true;
Re: Discussion topic for more easily enable / disable BOPCheck in Check Geometry
Thank your immediately PR

Warning: off topic!
While you are fooling around at TaskCheckGeometry getting familiarized with the code,

it would be nice to get following FR solved:
There is this possibility to "save" data from this tab to clipboard.
Perhaps for communication with your team mate to solve some problems.

But there is no way, except screenshots, for part below.
Would it possible to repeat output at least to report view for further access.
Otherwise you will have only some "deadlocked" information.

-
- Veteran
- Posts: 4569
- Joined: Thu Apr 05, 2018 1:53 am
Re: Discussion topic for more easily enable / disable BOPCheck in Check Geometry
This is a good idea. I wouldn't want to just take over the clipboard since the user might have something in it he wants to keep. I think it should go to the report view whenever an error is found. It is then simple enough to copy that information to the clipboard should the user wish to do so. I'll do this as a separate pull request since it is a separate matter. https://github.com/FreeCAD/FreeCAD/pull/2293UR_ wrote: ↑Tue Jun 25, 2019 4:40 amThank your immediately PR![]()
Warning: off topic!
While you are fooling around at TaskCheckGeometry getting familiarized with the code,![]()
it would be nice to get following FR solved:
There is this possibility to "save" data from this tab to clipboard.
Perhaps for communication with your team mate to solve some problems.![]()
In this video I have 2 objects in the document. One (Revolve) has some normal BRep errors that are found without BOP check enabled. The other (Compound001) has BOP Algo errors not found during the usual check without BOP check enabled.
Re: Discussion topic for more easily enable / disable BOPCheck in Check Geometry
Thank you for this prompt delivery!TheMarkster wrote: ↑Tue Jun 25, 2019 7:47 pm I'll do this as a separate pull request since it is a separate matter.
Re: Discussion topic for more easily enable / disable BOPCheck in Check Geometry
Looks good! I have a small suggestion, which is to simplify the tool tip message like this:
"Extra boolean operations check that can sometimes find errors that the regular geometry check misses, but which said These errors do not always mean the checked object is unusable."
so it now reads:
"Extra boolean operations check that can sometimes find errors that the regular geometry check misses. These errors do not always mean the checked object is unusable."
I like that too. (And it's interesting to see how the original thing requested in the ticket gets better).
Thank you both!
Re: Discussion topic for more easily enable / disable BOPCheck in Check Geometry
Oops - I just saw that the PR was already merged.
Re: Discussion topic for more easily enable / disable BOPCheck in Check Geometry
Can issue #4034 be closed ?
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
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