I had my shadow volume scheme working with vertex programs extruding quads for zpass. I had for each vertex two positions in a array, each one with 1 and 0 for the w coordinate. When calculating the silhouette, I created the indices so that when drawing, a vertex program would extrude properly the vertices.
Everything cool so far and working. Then, I read in an NVIDIA paper that you could optimize the zpass geometry, rendering triangles instead of quads, with one vertex of the triangle being external (-lightX, -lightY, -lightZ, -1).
So what I did was to create a simple array, with one entry for each vertex position plus 1. The first position would have (-lightX, -lightY, -lightZ, -1). A vertex program isn’t needed and I create the zpass geometry with triangles where the last index of each triangles points to vertex 0.
Everything great and working, except it is slow! I’m running on a GF3 with det 52.13. I can’t see where I’m doing anything wrong, and with all scenarios I’ve tested, the results are allways slower then drawing quads.
Can someone help me? Am I doing something wrong? Or is it the card?
Thanks…