Log in or register to post comments

Weird Triangles

July 5, 2012 - 1:06pm #1

Hello,

I have been experimenting with the ImageTargets project in hopes of loading my own model. Using an obj2openGL by heikobehrens, I have made a .h file and I have gotten something to load that is not a teapot. However, whatever wraps around it has empty triangles inside and I cannot decide whether it is my texture files (I have tried actual textures, the teapot textures and a plain red png) or if it is my .h file. 

I've attached a screenshot in hopes to better demonstrate my bug.

Thanks!

sbhuiyan

Weird Triangles

July 7, 2012 - 7:06pm #6


just a test


Yes it appears that there is an issue - thanks for bringing this to my attention.

Weird Triangles

July 5, 2012 - 3:09pm #5

I added as an image [img] using the button on the formatting bar. 

Weird Triangles

July 5, 2012 - 2:38pm #4

I can't see it either. How did you inline it to your post?

Weird Triangles

July 5, 2012 - 1:50pm #3

Thanks! I don't think its the direction of the winding triangles problem but I will attempt to fix via triangulation. I will update you if it works!

Just wondering if my screenshot showed up for anyone else cz its not showing up when I view my OP. 

 

Weird Triangles

July 5, 2012 - 1:13pm #2

What you're describing may arise from either model triangulation or the direction of the winding of the triangles. OpenGL ES only supports triangles (not quads). Make sure you have triangulated the model, any 3D modeling software should be able to do this. It is also possible the model has triangles winding in different directions (some clockwise, some counter-clockwise). This can happen when the normals are incorrect in the modeling software. In this case, try turning off culling: glDisable(GL_CULL_FACE);

Log in or register to post comments