Handle triangulated faces of the convex hull#7933
Draft
Conversation
to be removed later [skip ci]
8f6eb2d to
315a8fb
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem Description
Halfspace intersection (with or without constructions) does not handle the fact that CGAL's convex hull implementation always returns a triangulated hull. In case the dual has a face made of 4 or more coplanar points, this face is triangulated and this results in duplicated vertices in the primal.
Current Status
For now, I did a simple hack in the version without constructions to make sure that my diagnostic was correct. With the hack the test added passes.
IMO, the right fix should be to add a new named parameter in CH3 to fill an edge property map indicating if an edge is between two planar faces of the convex hull. We can do it greedily or modify the current code to detect that during the intersection test in
find_visible_set()(basically where I added the comment). This would need to update the CH3 convex to addOrientation_3()(p1,p2,p3,p4). One interesting thing to note is that in the current implementation, a non-triangle face of the convex hull is stared with the last point added in the face (and in particular TDS::Face_handle are all "new" each time a point is found, so that cannot be put in a map for example).Release Management