Interface DepthBufferConfig

The depth buffer to limit the ray marching distance when rendering the sky / atmosphere.

interface DepthBufferConfig {
    reverseZ?: boolean;
    texture: GPUTexture;
    view?: GPUTextureView;
}

Properties

reverseZ?: boolean

Specifiy if the depth buffer range is [0, 1] (reverse z) or [1, 0] (default). Defaults to false.

texture: GPUTexture

The depth buffer texture.

view?: GPUTextureView

A texture view to use for the depth buffer. If texture has a depth-stencil format, this view must be a "depth-only" view (to support binding it as a texture_2d<f32>).

If this is not present, a new view is created from the given texture.