Directx 9

Depth shadow mapping Dx9 depth-range gotchas

Pretty much everyone wants to use texture shadows in their real-time scenes these days; since they are calculated entirely on the GPU they scale well with modern chipsets, they are capable of shadowing alpha-rejected materials correctly (both as casters and receivers), they can be extended relatively simply to have soft edges, a variable penumbra and opacity with distance, and all kinds of other nice features. Depth-shadowmapping is the approach whereby you render the light-space depth (or some derivative thereof) of the shadow caster into a (typically floating point) shadow texture, then when rendering the main scene perform comparisons of the light-space depth of the pixel being rendered versus what is stored in that shadow texture.

Read more →