Skip to content

Fixed a problem with coincident points due to rounding in single precision

In a private communication with @jpouderoux two problems were identified with the new polyhedron clipping and contouring algorithm.

The first problem appeared when the contours are close to existing points, and, due to rounding errors in single precision, points that were slightly different were treated as being coincident. This is now solved by using a multimap, rather than a normal map in GetContourPoints and subsequent functions. This is addressed in the new TestPolyhedron7 test.

The second problem is that two input cells were not handled because they could not be triangulated in a non-manifold way. This is due to the input polyhedra that have severely twisted faces. These cells do not adhere to the polygonal faces should be planar prerequisite. The new test TestPolyhedron8 ensures that the contouring does work, but also shows that the two difficult cells are not contoured.

Edited by Joachim Pouderoux

Merge request reports

Loading