Depth Complexity

Depth Complexity

The maximum number of fragments falling that could be falling into any pixel.

Determining the depth complexity #

  1. Have a stencil buffer, the same size of the render target
  2. Render the scene once without the depth buffer
  3. For each fragment, increase the integer in the stencil buffer (in the FS)
  4. Using this buffer as a texture, create a new render target that is half size in both dimensions. The fragment shader takes 4 values from the previous stencil buffer and writes the max.
  5. repeat log(n) rendering passes, to compute the maximum depth compexity
Calendar October 22, 2023