11-05-2019, 09:18 PM
Hi Again,
After digging through the source code once more (which is an excellent code base by the way and it makes you feel that it was written by very smart people) I was able to figure it out. The issue is related to the LibTessDotNet library, more specifically it happens when creating the contour for the end cap. Since the segment index was set to 0, the vertices get welded with the first cap vertices causing the scaling to be dependent on the first cap. Whereas the contour should be created for last segment index.
Also, I think the same kind of behaviour will happen when creating volume holes for the caps (Just a guess, I haven't tested it out yet).
Here's a screenshot that demonstrates the fix: https://pasteboard.co/IFkHkgA.png
And here's the expected result: https://pasteboard.co/IFkIRbO.png
Hope this would be helpful for someone else
Best,
Maabed
After digging through the source code once more (which is an excellent code base by the way and it makes you feel that it was written by very smart people) I was able to figure it out. The issue is related to the LibTessDotNet library, more specifically it happens when creating the contour for the end cap. Since the segment index was set to 0, the vertices get welded with the first cap vertices causing the scaling to be dependent on the first cap. Whereas the contour should be created for last segment index.
Also, I think the same kind of behaviour will happen when creating volume holes for the caps (Just a guess, I haven't tested it out yet).
Here's a screenshot that demonstrates the fix: https://pasteboard.co/IFkHkgA.png
And here's the expected result: https://pasteboard.co/IFkIRbO.png
Hope this would be helpful for someone else
Best,
Maabed