One sided surfaces

Started by
0 comments, last by Chum 17 years, 6 months ago
I'm drawing a cube, but winding the triangles (each side is 2 tris) CLOCKWISE, because I want the cube to be "inside out." That is, I want it to be facing so that "normally" the viewer is in the center looking at the "inside" of the box (similar to a skybox.) The difference is, for debugging purposes, I'm looking at this box from OUTSIDE -- basically, it's acting as my "rotating cube" in a sample app. Since I'm doing glPolygonMode(GL_FRONT, GL_FILL), I'd EXPECT to only be able to see the back-sides of the cube -- that is, I'd think that the sides nearest me would be invisible, and I'd only see the 3 sides furthest from me. Instead, that sort-a/kind-a works, but I get this weird sort of distorted view that seems to show all 6-sides, kind-of, but not quite exactly -- the near ones have a sort of transparency to them. The texture I'm using on my cube can be seen here and a screenshot is here. Can someone explain why I'm getting these odd results? Thanks!
-- 3rd time Open-GL n00b. Maybe this time I'll learn it! :)
Advertisement
Duh. Nevermind...

I thought CullFace was on by default. gl.glEnable (GL.GL_CULL_FACE); fixed the problem.

I was going to delete this post, but decided to leave it up, with the solution, for anyone searching the archives.

Sorry for the interruption...
-- 3rd time Open-GL n00b. Maybe this time I'll learn it! :)

This topic is closed to new replies.

Advertisement