blinking objects because of overlap

is there any way to get rid of that blinking OpenGL does when objects move over top of eachother? it seems to not be able to decide which plane to display, so it just blinks them on and off. could this just be my video card? (voodoo 4500)

I have a bunch of random objects, and trying to figure out how to make them not collide, while still being random, is something I’d like to avoid.

thanks in advance

Hi.
I dont know how to solve it but its called z fighting. Do a search on this on these forums and you may find a solution.

bump out the near plane, or move in the far plane when you set up the perspective matrix

Originally posted by zerodot:
[b]is there any way to get rid of that blinking OpenGL does when objects move over top of eachother? it seems to not be able to decide which plane to display, so it just blinks them on and off. could this just be my video card? (voodoo 4500)

I have a bunch of random objects, and trying to figure out how to make them not collide, while still being random, is something I’d like to avoid.

thanks in advance[/b]

As others said, what you’re having is objects “Z-fight”. If two objects are exactly at the same distance from de camera, probably it’s unsolvable. Try offsetting a little one object from the other.
If there’s a difference in distance but you still see artifacts, try increasing the zNear value you’re using. eg. if you know your nearest object (to the cam) is at 20 units, you can use 10 as the zNear, and it will probably solve it.