Intersect and subtract of 2 overlapped ExtrudePolygon - #2

Hello everyone,
i have a problem aboout 2 overlapped ExtrudedPolygon when i interset or subtract with another ExtrudeShapeCustom

I dont understand why the wrench is cutted and why it appear deepest than the quare

https://playground.babylonjs.com/#LFWQQK

Thank you in advance

Your playground does not work at all for me, but pinging @JohnK and @Evgeni_Popov who are awesome with geometry in case they have any ideas ?

It seems the CSG algorithm does not like that the tail of the wrench goes inside the square…

If you use CSG to union the wrench and the square first, it seems to be better:

https://playground.babylonjs.com/#LFWQQK#1

2 Likes

@Evgeni_Popov very thanks ! :slight_smile: