-
Notifications
You must be signed in to change notification settings - Fork 1
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
Add Hidden-surface determination #4
Comments
Occlusion culling and Back-face culling could be 2 pretty decent ones to consider. |
Note: Back-face culling is already implemented at Main.py, line: 120 'if nz <=0:' checks the length of the normal in the Z axis for the given triangle, if the value is negative it indicates that it is facing towards the camera, if it is positive that indicates its normal on the Z axis is running in the same direction as the camera, and hence is facing away from the camera. The nz value is set to -1 at Main.py, line: 116 'nz = -1', this is for the 'wiremesh' feature which displays a transparent surface and requires Back-face culling to be turned off. |
A large contributor to the slower performance on more polygons is pythons for loop's sluggishness and the more polygons there are to draw, the more sluggish it gets.
To reduce the amount of polygons that need to be drawn perhaps some Hidden-surface determination would be beneficial, thus increasing performance and allowing more real-time rendering.
A Wikipedia article on this topic
The text was updated successfully, but these errors were encountered: