This looks like zbuffer variations on your illumination pass.
some things to try:
Enable texturing during the zbuffer fill pass, this will keep the paths similar and may produce the same depth value for the generated fragments. Try enabling blending too.
Use glPolygonOffset to apply depth separation between passes.
if using shaders use z invariance.
You shouldn’t need all of these and 1 would be the least attractive option but the easiest solution. Your software should work on some hardware without any modifications.
the stragne think is that in an other older version of my engine a do exactly the same stuff (but i have different pixel shaders) and it works perfectly! why is that?
hey. I use this command in the ARB_vertex_program.
now the artifacts is less than before. but they still exist. If i try to render the depth pass using a vertex program? is it gonna work? i will try it. But thanks for making my understand what causes the problem!