-
Notifications
You must be signed in to change notification settings - Fork 120
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
end_shape() is closing shapes without 'CLOSE' #167
Comments
I believe this has something to do with the Delaunay triangulation algorithm of the It would be better to not use |
Yup. Kinda had a feeling it had something to do with the triangle lib. As a matter of fact, I got some error messages from that lib under certain circumstances (I think when there were too many segments, or something). If I shouldn't use |
For this particular case, rendering multiple lines to form a spiral would also work.
I don't have a definite answer. But, |
One option of fixing this could be to render the border and the mesh separately - we'll still use the result of triangulation for drawing the mesh but we treat the vertices as in line mode when drawing the border. @parsoyaarihant Should I give this approach a try? Seems quicker than incorporating PyOpenGL. (In this case I'll still incorporate PyOpenGL but the purpose of which would not include fixing this bug). |
Okay, I think inherently the triangulation approach will have some limitations compared to p5.js because they use path APIs for curves. As @marcrleonard mentioned, the triangle library gave some errors while triangulation.
I didnt get this part. |
@parsoyaarihant If I fix this bug by rendering the lines and the meshs separately, then incorporating PyOpenGL wouldn't be needed to fix this bug. However, it may still be worth incoporating PyOpenGL for using it in 3D mode and behavior consistancy between the Processing Language dialects? There could be a performance benefit too, but given triangulation isn't the bottleneck in scenes I tested in #173, this benefit is limited. |
Consider/run this code:
This creates a very gentle spiral. It appears that once the end angle > 360, the shape closes. This should not happen unless end_shape('CLOSE') is specified.
System information:
The text was updated successfully, but these errors were encountered: