Problems I've identified:
- on the two BEVEL gears, the author didn't quite know which values to use, leading to inconsistent radii on different parts of the gear. Result: broken geometry
- on the outer teeth-polygons of the BEVEL gears, the faces are flipped: the visible faces are the BACK faces. The normals still point outwards of the gear, which cannot give good results.
- it's using a GL_QUAD_STRIP, but on BEVEL gears the quads aren't planar. Is there even a "right" way to shade non-planar QUADs?
- the normal vectors are calculated in a way that's valid for the next QUAD submitted inside the GL_QUAD_STRIP, which would be perfect for glShadeModel(GL_FLAT). But since glShadeModel() is never called, the default GL_SMOOTH is used. The result is visible on all gears if you look close enough.
So.. it's a test-case. Fixing everything may make it beautiful, but not necessarily more useful as a test-case. Does this program have a certain purpose to test specific features that must continue to be used?
- on the two BEVEL gears, the author didn't quite know which values to use, leading to inconsistent radii on different parts of the gear. Result: broken geometry
- on the outer teeth-polygons of the BEVEL gears, the faces are flipped: the visible faces are the BACK faces. The normals still point outwards of the gear, which cannot give good results.
- it's using a GL_QUAD_STRIP, but on BEVEL gears the quads aren't planar. Is there even a "right" way to shade non-planar QUADs?
- the normal vectors are calculated in a way that's valid for the next QUAD submitted inside the GL_QUAD_STRIP, which would be perfect for glShadeModel(GL_FLAT). But since glShadeModel() is never called, the default GL_SMOOTH is used. The result is visible on all gears if you look close enough.
So.. it's a test-case. Fixing everything may make it beautiful, but not necessarily more useful as a test-case. Does this program have a certain purpose to test specific features that must continue to be used?
Comment