Archived

This topic is now archived and is closed to further replies.

Dakusan

Proposed questions over shadow volume techniques

Recommended Posts

First, whenever I refer to front or back facing polygons herein, it is with respect to the light source. This is all in regard to the paper RobustShadowVolumes.pdf at NVIDIA. Using Zpass: I understand why the infinitely projected quads of the silhouette edges are drawn for the shadow volume and why the front facing polygons are drawn to close off the shadow volume in the front, but then why even draw the back facing polygons projected from the light source to infinity? If the polys are drawn to infinity to close off the shadow volume on the infinity side, they would never be encountered as vertices can''t physically be past infinity. Using ZFail: Why not use the front facing polygons projected to infinity, the shadow volume would still be closed off at infinity, nothing would be lost, and the front facing list was already just used to close off the front of the shadow volume, so only 1 list would need to be kept on hand. As a matter of fact, what would make most sense to me would be to just send a complete list of all the front (or back) facing polygons, with silhouette edges being marked as an extra variable. With these, the whole shadow volume could be rendered in 1 pass using a high level vertex rasterization shader. So instead of using triangle_list, or triangle_strip, or quad_strip or whatever, you would have a triangle_shadow_volume_list with the following definition. struct Vertex { float X,Y,Z,W; //Only the position of the vertex needs to be sent for shadow volume info bool SilEdge; //Is a silhouette edge? } Step 1: Any triangle sent through the rasterizer would be drawn as a normal triangle using vertex shader #1. Step 2: Any triangle sent through the rasterizer would be drawn projected to infinity using shader #2. One shader constant is the light source. (If needed using zpass) Step 3: Send the triangle silhouette edges and the light source as a shader constant using shader #3 to render the quad sides of the silhouette if SilEdge!=0 for any of the 3 vertices. This would effectively make 3 passes of all the triangles in the occluder to 1, and back facing polys would not even be used. I believe this would physically cut at least half of the work a shadow volume engine would use.

Share this post


Link to post
Share on other sites
I love this place... third time I''ve posted a question here and third time a single proper reply was not given. I don''t think I''ll ever try here again, seems more like a place for begginners to help each other out I guess.

Share this post


Link to post
Share on other sites
I actually fully understand stencil shadow volumes and this is the first time I''ve read this post by you, but I''m not going to reply because your attitude sucks

figure it out on your own

Share this post


Link to post
Share on other sites