BRepFeat_SplitShape bug?

Hello,

I am seeing a problem in splitting surfaces using BRepFeat_SplitShape. The problem is:

A cylinder of radius = 10 and length = 100, two square headed cubes of 1*1*100 are put adjacent each other on one edge inside the cylinder, not touching the cylinder's border. I first used one cube to split the cylinder's faces, each circular face of the cylinder became two faces, one square face and a circular face with a square hole.

Then I use the second cube to split the cylinder, which in the code, is just the 3 edges who's not overlapping with the first square to split the circular face with the square hole. I am expecting the cylinder top/bottom faces become 3 faces, 2 squares and a circle with a 2*1 rectangle hole. This step the code is confused in LocOpe_BuildWires.cxx at Perform() function. It tries to find a wire on the face to close the 3 edges, and in this case, it found 2, one is 1 edge, the other is 3 edges. Then it tries to use all 4 edges on the hole plus the 3 passed in edges to create a face, which is obviously wrong.

What I need is to find all paths to close the 3 edges' wire, and among them find the smallest area patch, and use that path plus the 3 edges to create a face, and ignore all other paths.

I hope someone internally can reply me if you can't reproduce the problem, and then report it in your bug repo. if possible. I am working on an proposal to have e-training class hopefully early next year, and want to have it fixed.

Thanks.

Jane

Jane Hu's picture

Well, When I debug more, I found the problem may not happen in LocOpe_BuildWires.cxx at Perform(). It passed in an open wire with 3 edges. But then somehow the face created have 7 edges, and if I shade this face, it showed it's not two squares, but with some trianglar shaped empty space. Where is the code computing for the new face's wire then?

Thanks.

Jane