Open zs0510 opened 4 weeks ago
Thank you for this bug report. Can you please give us a data set and the parameters of the call so that we can try to reproduce and fix.
Sorry I cannot provide the data. However, this might not affect your debugging, as the issue can already be discovered by examining the code.
Note that GeometryFactory can have a look under an NDA if that helps, and in case you use this algorithm professionally for Tencent.
The problem is still there. So let's not just put it under the carpet.
@zs0510 does your input mesh start with some degenerate faces, or were they produced by the remeshing itself?
Sorry I didn't see your comment in time. In my previous check, I remembered that the input mesh was without degenerate faces. I will check the input mesh again tomorrow.
I checked the mesh and found that the number of degenerate faces was 0 before remeshing.
What kernel do you use ? I ask as when using Exacxt_predicates_inexact_constructions_kernel
no degenerate faces should be created.
@zs0510 could you please try https://github.com/CGAL/cgal/pull/8418 and let us know if it fixes the issue you are having?
Sorry, I can't test it right now because the previous input data is now unavailable. The tool I'm working on involves a number of steps that are in iterative development. I will get in touch with you in time if this problem still occurs later. Thanks!
Please use the following template to help us solving your issue.
Issue Details
I occasionally encounter an infinite loop issue when using Remeshing, and upon investigation, I found that the fix_degenerate_faces function has design flaws. There are two problems with this function: 1. Previously processed degenerate faces are processed repeatedly (because the face becomes degenerate again when processing other degenerate faces); 2. It doesn't avoid introducing new degenerate faces while fixing degenerate faces. On my own computer, I can temporarily avoid the program falling into an infinite loop by recording the processed degenerate faces. Below is my local solution code (with 3 new lines added) for reference only.
Source Code
Environment