4#ifndef vtkWebGPUComputeFrustumCuller_h
5#define vtkWebGPUComputeFrustumCuller_h
9#include "vtkRenderingWebGPUModule.h"
13VTK_ABI_NAMESPACE_BEGIN
39 vtkRenderer* renderer,
vtkProp** propList,
int& listLength,
int& initialized)
override;
54 void CreateInputBoundsBuffer(
vtkProp** propList,
unsigned int nbProps);
59 void CreateOutputIndicesBuffer(
int nbProps);
68 void CreateViewProjMatrixBuffer(
const std::vector<float>& matrixData);
76 void ResizeCuller(
vtkProp** propList,
int propsCount);
82 void ResizeBoundsBuffer(
vtkProp** propList,
int newPropsCount);
87 void ResizeOutputIndicesBuffer(
int newPropsCount);
93 void ResizeScratchList(
vtkProp** propList,
int listLength);
103 void TriggerBoundsRecomputation(
vtkProp** propList,
int listLength);
108 void UpdateBoundsBuffer(
vtkProp** propList,
int listLength);
119 static void OutputObjectCountMapCallback(
const void* mappedData,
void* userdata);
126 static void OutputObjectIndicesMapCallback(
const void* mappedData,
void* userdata);
142 struct OutputIndicesCallbackData
148 int* indicesCount =
nullptr;
151 std::vector<vtkProp*>* scratchList =
nullptr;
157 int PreviousPropsCount = -1;
166 std::vector<vtkProp*> CallbackScratchList;
169 int InputBoundsBufferIndex = -1;
171 int CameraViewProjMatrixBufferIndex = -1;
175 int OutputIndicesBufferIndex = -1;
177 int OutputObjectCountBufferIndex = -1;
a superclass for prop cullers
a simple class to control print indentation
abstract superclass for all actors, volumes and annotations
abstract specification for renderers
Hold a reference to a vtkObjectBase instance.
This culler culls props to the camera view frustum using WebGPU compute shaders.
vtkWebGPUComputeFrustumCuller()
virtual double Cull(vtkRenderer *renderer, vtkProp **propList, int &listLength, int &initialized) override
This is called outside the render loop by vtkRenderer.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
~vtkWebGPUComputeFrustumCuller() override
static vtkWebGPUComputeFrustumCuller * New()