Visual diff (Restored)

Everything DG Kernel: Technical discussions and issues
Post Reply
sarge
Posts: 2
Joined: Mon Jul 01, 2024 12:14 pm

Visual diff (Restored)

Post by sarge »

We have been using Boolean Operations to compare surfaces imported via vrml. The idea is to present visually deviation of a scanned object from the designed exact surface.
We get exceptions in Boolean operations regularly. Is there a better way to do this?
Thank You
Prashant Kande
Posts: 65
Joined: Tue Jun 18, 2024 6:12 am

Re: Visual diff (Restored)

Post by Prashant Kande »

Hi

To be brief, comparing surfaces like you do needs a specifically designed algorithm. Boolean Operations are too complicated and hence not robust enough for the purpose. See below. The diff on the other hand is not that complicated and can be very robust.

Most likely you are trying to compare objects which have close geometry, nearly coinciding. This is very difficult case because the first thing Boolops do is calculation of the intersection curve(s). When surfaces simply (nearly) touch one another the calculation becomes unreliable simply because the intersection is not well defined: very small change in angle can make them coincide completely, where normal intersection does not work and another algorithm is executing.

This should be handled, but situation is very complicated and there are situations which we did not catch yet. If you see something happening consistently, we would like to see it.

Generally Boolean Operations are very complicated to handle any arbitrary input. We have spent a lot of time handling the coplanar situation above and the case when intersection curves actually merge into a bunch. My guess is that to get it working without an error in say 1000 operations in a row in your satiation can take about two years. Will this investment pay off for us? I am not sure at the moment.
Nick
Prashant Kande
Posts: 65
Joined: Tue Jun 18, 2024 6:12 am

Update July 2024

Post by Prashant Kande »

This was an early thread. Since then, we have revisited Boolean Operations on meshes, used in this particular application, several times and they are pretty robust now.

For completeness: Boolean operations on BRep geometries are implemented in the Open Cascade engine and are as solid as it gets.

Regards
sarge
Posts: 2
Joined: Mon Jul 01, 2024 12:14 pm

Re: Visual diff (Restored)

Post by sarge »

Is it possible to cut a hole in a mesh with a brep cylinder created via IStdShape_DG or other means?
Prashant Kande
Posts: 65
Joined: Tue Jun 18, 2024 6:12 am

Re: Visual diff (Restored)

Post by Prashant Kande »

Sure.

When at least one of the objects in a Boolean operation is a mesh, the result will be a mesh also.
If both are brep the result is brep.

Cheers
Post Reply