   Missing / Transparent faces issue
  I'm in the process of writing an abstraction layer over OpenGL, and I'm having some issues drawing a textured (.obj) mesh. I've written a loader which seemed to work fine when the mesh was just pure white, but now that it's textured I see there are weird problems on some of the faces. Some of the faces are just flat out missing, which would lead me to believe it's a normals problem, but other faces aren't quite missing, they seem to be almost "transparent". [edit] I've noticed from further studying that the "transparent" effect is caused by faces being drawn in front of others that shouldn't be. Is this a z-depth issue then?This is my drawing code:pastebinAnd this is the code that loads the .obj mesh (probably not that efficient but I just want results for now):pastebinAny help would be greatly appreciated : )   
  I don't really get what you mean by "transparency", but from your image I'll guess its some kind of backface culling/ triangle winding issue.Do you still have the problem if you set glDisable(GL_CULL_FACE) in your initialization?Did you have lighting enabled when you were drawing a white cube, so that you could clearly see that all the sides were correct? I'm guessing its not really a texture issue, but I could be mistaken.Also make sure you enable GL_DEPTH_TEST.[Edited by - karwosts on May 22, 2010 4:54:04 PM];  Hmm, I tried glDisable(GL_CULL_FACE) and glEnable(GL_DEPTH_TEST), but no change.I was incorrect to call the effect "transparency", I believe now that what's really happening is faces that should be drawn are being overlapped by faces that *should* be behind them, but for some reason are getting drawn in front.As you can see, the '3' that should be on the face is getting clipped by the face behind it, which makes a really weird effect.   ;  That is certainly odd. That's exactly the behavior I'd expect to see if you have depth test disabled, but you said it is enabled. Can you post more opengl rendering stuff? Initialization and try to include every call you make over the frame, hopefully it is not too much. Make sure to include your projection matrix setup too.   ;  I fixed it! The problem was that my initialization code wasn't having any effect because it was being called prior to SDL_SetVideoMode, which apparently is a no no.Once I moved my GL initialization code to be after this statement, glEnable(GL_DEPTH_TEST) fixed my problems. : )Thanks much for the help!   