13#ifndef vtkWebGPUVolumeRayCastContribution_h
14#define vtkWebGPUVolumeRayCastContribution_h
16#include "vtkABINamespace.h"
23VTK_ABI_NAMESPACE_BEGIN
56 virtual bool FetchBrick(
const int brick[3],
int slotSize,
void* voxels) = 0;
63 const int vtkNotUsed(brick)[3],
int vtkNotUsed(slotSize),
unsigned char* vtkNotUsed(voxels))
125 double ScalarRange[4][2] = { { 0.0, 1.0 }, { 0.0, 1.0 }, { 0.0, 1.0 }, { 0.0, 1.0 } };
127 double GradientRange[4][2] = { { 0.0, 1.0 }, { 0.0, 1.0 }, { 0.0, 1.0 }, { 0.0, 1.0 } };
topologically and geometrically regular array of data
represent and manipulate 4x4 transformation matrices
maintain a list of planes
represents the common properties for rendering a volume.
represents a volume (data & properties) in a rendered scene
GPU ray cast volume mapper for the WebGPU backend.
Where the coordinator gets the voxels of a brick from.
virtual bool FetchMask(const int brick[3], int slotSize, unsigned char *voxels)
Fill voxels with one byte per voxel of the same brick, non zero where the voxel is not to be drawn.
virtual bool FetchBrick(const int brick[3], int slotSize, void *voxels)=0
Copy the brick at brick, with a one voxel apron from its neighbours, into voxels, which holds slotSiz...
virtual ~vtkWebGPUVolumeBrickSource()=default
One input offered up to be ray cast alongside the others.
vtkWebGPUVolumeBrickSource * BrickSource
Where the coordinator asks for voxels, and whether they come back as bytes or floats.
bool Streaming
Read a brick at a time.
vtkMTimeType BrickTime
When the voxels themselves last changed.
bool Transfer2DHasYAxisArray
const std::vector< std::uint16_t > * Transfer2DTable
RGBA16Float texels, vtkWebGPUVolumeTransferFunction2DSize squared per component.
int PoolChannels
How many channels of a pool slot one voxel takes.
double GradientRange[4][2]
Range each component's gradient opacity function was tabulated over.
bool HasMask
Whether some voxels are hidden, and whether hiding one hides what interpolates through it.
const std::vector< std::uint16_t > * GradientTable
double ScalarRange[4][2]
Range each component's colour and opacity functions were tabulated over.
const std::vector< std::uint16_t > * ColorTable
RGBA16Float texels, vtkWebGPUVolumeTransferFunctionSize of each, one set per component.
int CellSize
Edge length and count of the acceleration cells, which say where the volume is empty.
const std::vector< std::uint16_t > * OpacityTable
std::uint32_t PropId
Index of this volume's prop in the renderer, which selection reports as the prop id.
int PrimaryComponent
The component the intensity blend modes and the acceleration structure look at.
int NumberOfComponents
How many components are rendered, at most four, and whether each carries its own transfer functions o...
vtkPlaneCollection * ClippingPlanes
Clipping planes of the mapper that owns this input, if any.
vtkVolumeProperty * Property
vtkMatrix4x4 * WorldMatrix
Placement of the prop that carries this input.
bool Transfer2D
Whether colour and opacity come from a two dimensional transfer function, and whether its second axis...
float ValueScale
Turns a raw texel back into a scalar: scalar = texel * ValueScale + ValueBias.
bool CellData
Whether the samples are the cells rather than the points, which puts them half a cell in from the edg...
const std::vector< std::uint16_t > * LabelTable
RGBA16Float texels, vtkWebGPUVolumeTransferFunctionSize per label, row zero unused.
bool IndependentComponents
vtkMatrix4x4 * IndexToPhysical
Index space to the input's own coordinates.
const std::vector< float > * CellClassification
Two floats per cell: the largest opacity it maps to, and how much it varies.
int MaximumLabel
A label map mask names a transfer function per label, and MaskBlendFactor says how far to go from the...
vtkMTimeType CellsTime
When cells were last classified on their own, as bricks of a streamed volume arrive.
vtkWebGPUVolumeRayCastMapper * Mapper
Who offered this input, and which of its ports it came from.
vtkMTimeType ContentTime
Bumped whenever any of the data above is rebuilt, so the coordinator can leave the layers and blocks ...
vtkTypeUInt32 vtkMTimeType
constexpr int vtkWebGPUVolumeTransferFunction2DSize
Edge length of a resampled two dimensional transfer function, in texels.
constexpr int vtkWebGPUVolumeTransferFunctionSize
Size of every tabulated transfer function, in texels.