View Full Version : fragment_program + multiple pass

10-15-2006, 07:37 AM

I wrote a classic fragment program that does 'per pixel lighting' and it works well with 1 lights.

I wants now to have multiple light and I try with multiple pass rendering. So I enable blending with the following lines :

glBlendFunc(GL_ONE, GL_ONE);

I also use the following depth test :


The problem is that I get strange results for the second lights. The light contribution for it seems not smooth.

I can provide more informations if needed.

Thanks for your help.

10-15-2006, 12:00 PM
Can you post a screenshot? Do you use user clip planes?

10-16-2006, 06:26 AM
[img=http://img235.imageshack.us/img235/1470/ppl1ax8.th.png] (http://img235.imageshack.us/my.php?image=ppl1ax8.png)

10-16-2006, 06:31 AM
Sorry for the previous post,

Here is the correct link : screenshot (http://img235.imageshack.us/my.php?image=ppl1ax8.png)

I use here only 2 spotlights...


10-16-2006, 12:41 PM
What exactly the screenshot represents? Can you post it in jpeg format?