Add BOPAlgo_PaveFiller for better boolean operation performance #234
Replies: 2 comments
-
|
Mmm it looks like ocjs filters it: The solution is the one I have been failing at for a little while - forking ocjs to make it work with this. That said, this is a very interesting API - I wonder how it could be included in the replicad API in a non intrusive way. |
Beta Was this translation helpful? Give feedback.
-
|
Oh! that's a very useful pointer, I wasn't aware of the filtering in ocjs. I'm hesitant to dive into a forking ocjs, and it'll be a couple weeks before I have more time to spend on this particular topic. For now I'll plan on pursuing the CellsBuilder approach, for our use case a simple pass-through of the OC types would be sufficient but I'll do some thinking on how a more integrated replicad api might look. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
I guess this might actually be a FR to add PaveFiller to the replicad build. This class enables faster performance when doing multiple boolean operations on the same set of input shapes. Eg: Cut A with B and get A intersect B.
Instead of performing the cut then the intersection independently, having access to PaveFiller would allow construction of a single PaveFiller which could be passed to both the Intersect and Cut operations. Both of these operations (and all boolean operations in OCCT) start by computing all intersected sub-spaces between the inputs (eg: for a boolean operation on A, B, C all of the following are computed: A excluding B,C; B excluding A,C; C excluding A,B; A intersect B but not C; A intersect C but not B; B intersect C but not A; and A intersect B and C). Then the appropriate sub-spaces are included in the result depending on which operation is being performed. BOPAlgo_PaveFiller is the class name OCCT uses for the module that computes and stores this intermediate stage of the boolean computation. Passing a single PaveFiller to multiple operations allows for reusing the expensive computation of all these various subspaces.
Normally I'd pursue this as a custom build, but I find that when I add BOPAlgo_PaveFiller to the build config I get an exception saying
Requested binding "BOPAlgo_PaveFiller" does not exist. I'm not sure how to proceed from here, so posting in case someone has guidance.BOPAlgo_CellsBuilder provides a similar functionality and doesn't generate the same build error. For now I'm proceeding with the CellsBuilder, but long term the syntax of PaveFiller is closer to the already available BREPAlgoAPI classes.
-Tristan
Beta Was this translation helpful? Give feedback.
All reactions