PDA

View Full Version : Different z buffer with VP?



Coluna
08-23-2003, 09:14 PM
Hi all;
When im using a vp to draw a mesh, could the z-buffer differs from the default opgnl pipeline? im drawing the model with the default one, and blending with a lighted model from a vp, but even with GL_LEQUAL and poly offset 1.0,1.0 it doesnt work.
Thanx

NitroGL
08-23-2003, 09:19 PM
See issue #64 in the ARB_vertex_program spec.

Coluna
08-23-2003, 10:40 PM
Thank u for the reply...I used NV_position_invariant , polygon offset (disabling when drawing the original model), depth func GL_LEQUAL, glDepthMask(0), and the problem persists ... another sugestion?

Korval
08-24-2003, 01:46 AM
This may sound a bit strange, but bear with me.

When you use NV_position_invariant, are you using ARB_vp, or NV_vp1_1/vp2? Because they have two different conventions for specifying position invariance.

bakery2k
08-24-2003, 06:56 AM
What card are you using?

Coluna
08-24-2003, 02:38 PM
Im using NV_vp1_1, with a geforce 2 mx400 ...

Tom Nuydens
08-24-2003, 02:54 PM
I don't think option_invariant is going to work if one pass is done in HW (fixed function) and the other in software (VP). Try doing both passes with a VP and see if that fixes the problem.

-- Tom

Coluna
08-24-2003, 05:03 PM
Ok. But i tried like this:
- render the object solid with the first light;
- render the others lights with the options (poly offset, mask90) ...) blending with the previous one, all in vp and it didnt work...very strange ...when i dont draw the solid one, i can see the transparent model being iluminated... the vp in my GPU is done in CPU? would it be the error?

SirKnight
08-24-2003, 07:55 PM
The GeForce 2 does not support vertex_program of any variation (NV or ARB) in hardware. Only GeForce 3 and up (not including the GeForce 4 MX of course). So if you are going to use NV_vertex_program on a GeForce 2, either do all of your vertex transforms in a vertex_program or not use NV_vertex_program at all. There is no way to solve the invariance if you are using a card that does not support the vertex_program extension in hardware, no matter what option you choose.


-SirKnight

Coluna
08-24-2003, 09:02 PM
Thanx all posts....i found out that the biggest problem was i was setting poly offset with 1,1 , but for the blended ones i should use -1,-1 ....