Skip to content

VolumePass ​

Methods ​

computeTiming ​

Decide whether the ray cast pass should render into a reduced viewport, based on the interactor's animation frame rate and the mappers' sample distance settings.

ArgumentTypeRequiredDescription
viewNodevtkWebGPURenderWindowYes

createClearEncoder ​

Create the encoder that clears the volume color texture before the first group of volumes is ray cast.

ArgumentTypeRequiredDescription
viewNodevtkWebGPURenderWindowYes

createCopyEncoder ​

Create the encoder that blends the volume color texture back into the render window's color attachment.

ArgumentTypeRequiredDescription
viewNodevtkWebGPURenderWindowYes

createDepthRangeEncoder ​

Create the encoder that renders the volume bounding boxes into the two min/max depth textures.

ArgumentTypeRequiredDescription
viewNodevtkWebGPURenderWindowYes

createMergeEncoder ​

Create the encoder that composites a later group of volumes onto the result of the previous groups.

ArgumentTypeRequiredDescription
viewNodevtkWebGPURenderWindowYes

drawDepthRange ​

Render the bounding box geometry to fill the min and max depth textures the ray cast pass samples between.

ArgumentTypeRequiredDescription
renNodevtkWebGPURendererYes
viewNodevtkWebGPURenderWindowYes

extend ​

Method used to decorate a given object (publicAPI+model) with vtkWebGPUVolumePass characteristics.

ArgumentTypeRequiredDescription
publicAPIYesobject on which methods will be bounds (public)
modelYesobject on which data structure will be bounds (protected)
initialValuesIWebGPUVolumePassInitialValuesNo(default: {})

getColorTextureView ​

Get the color texture view this pass composites its result into.

getDepthTextureView ​

Get the depth texture view geometry has already been rendered into.

initialize ​

Create the encoders, textures and full screen quads this pass renders with. Anything already created is left alone.

ArgumentTypeRequiredDescription
viewNodevtkWebGPURenderWindowYes

newInstance ​

Method used to create a new instance of vtkWebGPUVolumePass.

ArgumentTypeRequiredDescription
initialValuesIWebGPUVolumePassInitialValuesNofor pre-setting some of its content

rayCastPass ​

Ray cast one group of volumes into the volume color texture.

ArgumentTypeRequiredDescription
viewNodevtkWebGPURenderWindowYes
renNodevtkWebGPURendererYes
volumesArray[vtkWebGPUVolume]YesThe group of volumes to render.

releaseGraphicsResources ​

Free the encoders, textures, quads and buffers this pass holds.

renderDepthBounds ​

Build the bounding box polydata, upload it and draw it through the depth range encoder.

ArgumentTypeRequiredDescription
renNodevtkWebGPURendererYes
viewNodevtkWebGPURenderWindowYes

setColorTextureView ​

Set the color texture view this pass composites its result into.

setDepthTextureView ​

Set the depth texture view geometry has already been rendered into.

setVolumes ​

Set the volumes this pass renders, marking the pass modified only when the list actually changed.

ArgumentTypeRequiredDescription
valArray[vtkWebGPUVolume]Yes

traverse ​

Render the volumes of a renderer: depth bounds first, then one ray cast pass per group of volumes, then a copy back into the render window.

ArgumentTypeRequiredDescription
renNodevtkWebGPURendererYes
viewNodevtkWebGPURenderWindowYes

updateDepthPolyData ​

Rebuild the polydata holding one cube per volume, clipped against the camera near plane, in stabilized coordinates.

ArgumentTypeRequiredDescription
renNodevtkWebGPURendererYes