Look at the gold globe in the centre, and you will see some of the edges have a triangular chunk taken out of them.
At first I thought, ‘depth buffer’ but GL_DEPTH_TEST is enabled, and I have called glEnable( GL_DEPTH ) also.
GL_CULLING is also enabled…
As you move forward in the scene, the position of the missing chunks moves, and sometimes, when the camera stops moving, everything looks fine.
I also noticed,that some of the triangles on the surface of the ships flicker between light and shadow as the camera moves, i.e you can see the triangles which make up the mesh…
I am assured that my meshes all have level surfaces…
i think this is a zbuffer problem… how are your settings?
how much zbufferbits? ( if you have a geforce, real zbufferbits = colorbits - stencilbits, had this one time 16bit color mode and 8bit stencil, result whas 8bit depthbuffer, not very nice indeed )
near/far clipplane settings? try to move the near more far away, and the far more near…
ok, the depthbufferdepth is choosen with the PIXELFORMATDESCRIPTOR struct, but, as i explained, depending on driver(-settings) it can be choosen automatically…
first, u create a spacetrading simulation… so i think your meshes dont need to come too near to the cam, so set near to 1.f … try if it is a problem to do so… second, perhaps you should use 2 depthbuffers_passes, means first you set your clipplanes to for example 100 -> 1000000 and render all things behind 100 ( planets mostly… ), then clear the depthbuffer and after you set it to .1f -> 100 to render the rest…
but the rest is just setting the depthbufferdepth to a higher res and try to set the near as far as possible ( and perhaps you can take the far a little nearer… )
btw, do you have culling enabled? glEnable( GL_CULL_FACE );… perhaps CW or CCW, like that there can be much stress taken away with z-buffer problems, too…
Clearing the depth buffer twice in a single frame? Isn’t that a bit extreme?
Just scale your distances down…
For an experiment, put your near and far clip planes back to the values they were at when you had the triangle flicker problem.
Then add this command at the start of your render loop…
glScalef(0.25f, 0.25f, 0.25f);
Do you see the improvement?
I’m not suggesting you use glScale (screws up normals), but it should indicate that your distances are too big…so long as everything is relative, you should do a uniform scale of all your coordinates and you’ll have no problem.