Edge Rewrite
// HTMLRewriter · presentation

This page was redesigned at the edge.

Cloudflare fetched the original article and streamed it through HTMLRewriter to apply an entirely new visual system without rebuilding the source page.

// request.cf · coarse context

A page that knows where it met you.

Only coarse request metadata is shown. This demo does not display or persist visitor IP addresses.

Country
US
Cloudflare location
CMH
Connection
HTTP/2
Language
Not provided

Ray ID: a227dd5b7927cf77

Jump to content

Depth peeling

From Wikipedia, the free encyclopedia

In computer graphics, depth peeling is an exact multipass method of order-independent transparency that extracts transparent fragments into depth layers and composites those layers in depth order.[1] Depth peeling has the advantage of being able to generate correct results even for complex images containing intersecting transparent objects.

Method

[edit]

Depth peeling works by rendering the image multiple times.[1] Depth peeling uses two Z buffers, one that works conventionally, and one that is not modified, and sets the minimum distance at which a fragment can be drawn without being discarded. For each pass, the previous pass' conventional Z-buffer is used as the minimal Z-buffer, so each pass removes already-captured nearer fragments and draws the next depth layer behind them.[1] The resulting images can then be composited in depth order to form a single image.[1] A major drawback of classical depth peeling is performance: it requires one geometry pass per peeled layer, so scenes with high depth complexity require many passes that each re-rasterize the transparent geometry.[2][3] Later variants reduce the number of passes by peeling multiple layers or both front and back layers in a pass.[2][3] Dual depth peeling reduces the geometry-pass count from N to N/2+1 by peeling one layer from the front and one from the back in each pass, while multi-layer depth peeling peels several layers per pass and reported up to an 8x speed-up in RGBA8 settings.[2][3]

References

[edit]
  1. 1 2 3 4 Everitt, Cass (2001-05-15). "Interactive Order-Independent Transparency" (PDF). Nvidia. Retrieved 2008-10-12.
  2. 1 2 3 Bavoil, Louis; Myers, Kevin. "Order Independent Transparency with Dual Depth Peeling" (PDF). Nvidia. Retrieved 2026-05-20.
  3. 1 2 3 Liu, Baoquan; Wei, Li-Yi; Xu, Ying-Qing. "Multi-Layer Depth Peeling via Fragment Sort" (PDF). Microsoft Research. Retrieved 2026-05-20.