Aller au contenu

RenderPassDepthStencilAttachment

data class RenderPassDepthStencilAttachment(
    val view: GPUTextureOrGPUTextureView, 
    val depthClearValue: Float? = null, 
    val depthLoadOp: GPULoadOp? = null, 
    val depthStoreOp: GPUStoreOp? = null, 
    val depthReadOnly: Boolean = false, 
    val stencilClearValue: GPUStencilValue, 
    val stencilLoadOp: GPULoadOp? = null, 
    val stencilStoreOp: GPUStoreOp? = null, 
    val stencilReadOnly: Boolean = false
) : GPURenderPassDepthStencilAttachment
Describes the depth and stencil operations for a render pass attachment.

Constructors

RenderPassDepthStencilAttachment

constructor(
    view: GPUTextureOrGPUTextureView, 
    depthClearValue: Float? = null, 
    depthLoadOp: GPULoadOp? = null, 
    depthStoreOp: GPUStoreOp? = null, 
    depthReadOnly: Boolean = false, 
    stencilClearValue: GPUStencilValue, 
    stencilLoadOp: GPULoadOp? = null, 
    stencilStoreOp: GPUStoreOp? = null, 
    stencilReadOnly: Boolean = false
)

Properties

depthClearValue

open override val depthClearValue: Float?
Indicates the value to clear view’s depth component to prior to executing the render pass. Ignored if depthLoadOp is not "clear". Must be between 0.0 and 1.0, inclusive.

depthLoadOp

open override val depthLoadOp: GPULoadOp?
Indicates the load operation to perform on view’s depth component prior to executing the render pass. Note: It is recommended to prefer clearing; see "clear" for details.

depthReadOnly

open override val depthReadOnly: Boolean
Indicates that the depth component of view is read only.

depthStoreOp

open override val depthStoreOp: GPUStoreOp?
The store operation to perform on view’s depth component after executing the render pass.

stencilClearValue

open override val stencilClearValue: GPUStencilValue
Indicates the value to clear view’s stencil component to prior to executing the render pass. Ignored if stencilLoadOp is not "clear". The value will be converted to the type of the stencil aspect of view by taking the same number of LSBs as the number of bits in the stencil aspect of one texel of view.

stencilLoadOp

open override val stencilLoadOp: GPULoadOp?
Indicates the load operation to perform on view’s stencil component prior to executing the render pass. Note: It is recommended to prefer clearing; see "clear" for details.

stencilReadOnly

open override val stencilReadOnly: Boolean
Indicates that the stencil component of view is read only.

stencilStoreOp

open override val stencilStoreOp: GPUStoreOp?
The store operation to perform on view’s stencil component after executing the render pass.

view

open override val view: GPUTextureOrGPUTextureView
Describes the texture subresource that will be output to and read from for this depth/stencil attachment. The subresource is determined by calling get as texture view(view).