Flickering Triangles
I've created an object by loading it as per lesson 10. One of the triangles in the object keeps flickering. Any ideas why?
ar you using opengl lighting with Normal calls..
it flickers in that case when the vert is backfacing
turn backface culling on
glEnable(GL_CULL_FACE);
glCullFace(GL_BACK/GL_FONT);
it flickers in that case when the vert is backfacing
turn backface culling on
glEnable(GL_CULL_FACE);
glCullFace(GL_BACK/GL_FONT);
----------------------------http://djoubert.co.uk
No lighting.
This is proper newbie stuff, I've done plenty of 2D work with opengl but this is my first true 3D.
This is proper newbie stuff, I've done plenty of 2D work with opengl but this is my first true 3D.
Have you accidently made two triangles very close together, i.e. on top of each other? If the depth range is big then this could be it.
--
Cheers,
Darren Clark
Cheers,
Darren Clark
depth range was set to 100 but this is more than adequate for my 8x8 model.
triangle count is right so not likely to have duplicated anywhere but will check.
I've got this funny feeling it is something to do with depth though.
Do I need to sort my triangles so the most distant is drawn first perhaps?
Is it a necessity baring in mind that I have no transparent objects?
triangle count is right so not likely to have duplicated anywhere but will check.
I've got this funny feeling it is something to do with depth though.
Do I need to sort my triangles so the most distant is drawn first perhaps?
Is it a necessity baring in mind that I have no transparent objects?
check your 'near plane' value -NOT- to be 0.00 (in DirectX)
A vid of my Pengo adv. remake in beta stage_____________
If you have two objects with exactly the same position, depth testing will get confused and could cause them to flicker, as you've described.
You'll often run into this if you have a "ground" plane and are placing objects directly on it. A solution is to have the "ground" to be something like 0.00001 lower than the X-axis. Nobody will be able to tell the difference.
So make sure these two triangles aren't directly overlapping each other. If not, post back and we can explore a few other things.
You'll often run into this if you have a "ground" plane and are placing objects directly on it. A solution is to have the "ground" to be something like 0.00001 lower than the X-axis. Nobody will be able to tell the difference.
So make sure these two triangles aren't directly overlapping each other. If not, post back and we can explore a few other things.
Without order nothing can exist - without chaos nothing can evolve.
Just checked as best I could and my object doesn't seem to have any duplicated traingles.
All of the triangles share at least 2 vertices with another triangle in the same object is this likely to cause problems?
near plane set to 0.1 far plane to 700.0 using OpenGL.
All of the triangles share at least 2 vertices with another triangle in the same object is this likely to cause problems?
near plane set to 0.1 far plane to 700.0 using OpenGL.
No, triangles in a mesh typically share vertices. That won't cause any problems.
Does the flicker occur when you translate/rotate? Or do they just always flicker?
Screenshots might help.
Does the flicker occur when you translate/rotate? Or do they just always flicker?
Screenshots might help.
Without order nothing can exist - without chaos nothing can evolve.
It always flickers.
I've added to the model in question recently and the flickering has died down but not completely gone. Thing is it makes it hard to get a screenie.
The flickering on this model isn't all that important as the player is unlikely to see the offending triangles only I'm trying to assimulate possible causes for when it does become an issue.
Do vertices have to defined in a specific order?
I've added to the model in question recently and the flickering has died down but not completely gone. Thing is it makes it hard to get a screenie.
The flickering on this model isn't all that important as the player is unlikely to see the offending triangles only I'm trying to assimulate possible causes for when it does become an issue.
Do vertices have to defined in a specific order?
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement