15 #include <vsg/nodes/Node.h>
16 #include <vsg/state/ArrayState.h>
26 using NodePath = std::vector<const Node*>;
27 using ArrayStateStack = std::vector<ref_ptr<ArrayState>>;
34 void apply(
const Node& node)
override;
35 void apply(
const StateGroup& stategroup)
override;
36 void apply(
const Transform& transform)
override;
37 void apply(
const LOD& lod)
override;
38 void apply(
const PagedLOD& plod)
override;
39 void apply(
const CullNode& cn)
override;
45 void apply(
const Geometry& geometry)
override;
49 void apply(
const Draw& draw)
override;
50 void apply(
const DrawIndexed& drawIndexed)
override;
52 void apply(
const BufferInfo& bufferInfo)
override;
53 void apply(
const ushortArray& array)
override;
54 void apply(
const uintArray& array)
override;
63 virtual void popTransform() = 0;
69 virtual bool intersectDraw(uint32_t firstVertex, uint32_t vertexCount, uint32_t firstInstance, uint32_t instanceCount) = 0;
72 virtual bool intersectDrawIndexed(uint32_t firstIndex, uint32_t indexCount, uint32_t firstInstance, uint32_t instanceCount) = 0;
75 std::vector<dmat4>&
localToWorldStack() {
return arrayStateStack.back()->localToWorldStack; }
78 std::vector<dmat4>&
worldToLocalStack() {
return arrayStateStack.back()->worldToLocalStack; }
81 ArrayStateStack arrayStateStack;
BindIndexBuffer command encapsulates vkCmdBindIndexBuffer call and associated settings.
Definition: BindIndexBuffer.h:28
BindVertexBuffers command encapsulates vkCmdBindVertexBuffers call and associated settings.
Definition: BindVertexBuffers.h:25
BufferInfo encapsulates the settings that map to VkDescriptorBufferInfo.
Definition: BufferInfo.h:27
CullNode that enables view frustum culling on a list of children.
Definition: CullGroup.h:23
Definition: CullNode.h:25
Definition: DepthSorted.h:27
DrawIndexed command encapsulates vkCmdDrawIndexed call and associated settings.
Definition: DrawIndexed.h:24
Draw command encapsulates vkCmdDraw call and associated settings.
Definition: Draw.h:24
Definition: Geometry.h:30
Definition: Intersector.h:24
virtual bool intersectDraw(uint32_t firstVertex, uint32_t vertexCount, uint32_t firstInstance, uint32_t instanceCount)=0
intersect with a vkCmdDraw primitive
virtual bool intersects(const dsphere &sphere)=0
check for intersection with sphere
std::vector< dmat4 > & worldToLocalStack()
get the current world to local matrix stack
Definition: Intersector.h:78
virtual bool intersectDrawIndexed(uint32_t firstIndex, uint32_t indexCount, uint32_t firstInstance, uint32_t instanceCount)=0
intersect with a vkCmdDrawIndexed primitive
virtual void pushTransform(const Transform &transform)=0
clone and transform this Intersector to provide a new Intersector in local coordinates
std::vector< dmat4 > & localToWorldStack()
get the current local to world matrix stack
Definition: Intersector.h:75
Definition: PagedLOD.h:36
Definition: StateGroup.h:32
Definition: VertexDraw.h:25
Definition: VertexIndexDraw.h:25