Issues with Region Difference (CurveBooleanDifference)

Hello,

Hope you are all doing fine !

I’ve encountered a weird behaviour with the region difference component and I can’t understand why it is happening…

Basically I have a tree of rectangularish closed planar curves that represent some floor panels, and a closed planar curve that represents a building’s footprint. I want to use the region difference component to remove/cut the panels that extends beyond the building.

The panel before the operation :

The panel after the operation :

It works perfectly in most cases. But in some cases the first panel gets completely removed while being inside the building’s footprint. I first encounterd this issues inside a python script with the function rs.CurveBolleanIntersection() but I’ve managed to reproduce it with the Grasshopper component.

The panel after the operation (issues) :

Here’s an extremely simplified version of my issue :
issuesWithBooleanIntersection.gh (12.2 KB)
I only kept the relevant data, I put an example that works and one that doesn’t. If you could explain to me what is so special with the first curve that it gets deleted and not the others. What am I doing wrong ?

Thanks for your help !

don’t know what’s going on exactly, but looks like exploding the curves and joining them together again fixes the issue

how did you get those curves?

Hello Inno,

Thank you for your reply.

Those curves are the results of a python script. They are all created following the same method.

I already noticed that by playing around with the curves, the issues get corrected. For example if you flip all the panels everything works perfectly. But I would like to understand why… Because for me the curves are all the same, so I dont understand why this specific curve get deleted everytime

If you want I can send a simplified version of my python script to see if I 'm doing something wrong.