15 #include <vsg/core/Mask.h>
16 #include <vsg/core/Object.h>
17 #include <vsg/core/type_name.h>
18 #include <vsg/maths/mat4.h>
37 class MatrixTransform;
44 class CulledPagedLODs;
48 class ViewDependentState;
51 class DirectionalLight;
55 class RecordedCommandBuffers;
63 explicit RecordTraversal(uint32_t in_maxSlot = 2, std::set<Bin*> in_bins = {});
68 template<
typename... Args>
74 std::size_t sizeofObject()
const noexcept
override {
return sizeof(
RecordTraversal); }
75 const char* className()
const noexcept
override {
return type_name<RecordTraversal>(); }
77 Mask traversalMask = MASK_ALL;
78 Mask overrideMask = MASK_OFF;
93 FrameStamp* getFrameStamp() {
return _frameStamp; }
98 void apply(
const Object&
object);
101 void apply(
const Group& group);
102 void apply(
const QuadGroup& quadGroup);
103 void apply(
const LOD& lod);
104 void apply(
const PagedLOD& pagedLOD);
105 void apply(
const CullGroup& cullGroup);
106 void apply(
const CullNode& cullNode);
107 void apply(
const DepthSorted& depthSorted);
108 void apply(
const Switch& sw);
111 void apply(
const Light& light);
112 void apply(
const AmbientLight& light);
113 void apply(
const DirectionalLight& light);
114 void apply(
const PointLight& light);
115 void apply(
const SpotLight& light);
118 void apply(
const Transform& transform);
119 void apply(
const MatrixTransform& mt);
120 void apply(
const StateGroup&
object);
121 void apply(
const Commands& commands);
122 void apply(
const Command& command);
125 void apply(
const View& view);
126 void apply(
const CommandGraph& commandGraph);
132 virtual ~RecordTraversal();
134 ref_ptr<FrameStamp> _frameStamp;
135 ref_ptr<State> _state;
138 ref_ptr<DatabasePager> _databasePager;
139 ref_ptr<CulledPagedLODs> _culledPagedLODs;
141 int32_t _minimumBinNumber = 0;
142 std::vector<ref_ptr<Bin>> _bins;
143 ref_ptr<ViewDependentState> _viewDependentState;
CommandBuffer encapsulates VkCommandBuffer.
Definition: CommandBuffer.h:27
FrameStamp represents the time and frame count of a specific frame.
Definition: FrameStamp.h:22
RecordTraversal traverses a scene graph doing view frustum culling and invoking state/commands to rec...
Definition: RecordTraversal.h:61
State * getState()
get the current State object used to track state and projection/modelview matrices for the current su...
Definition: RecordTraversal.h:84
uint32_t deviceID() const
get the current DeviceID for the current subgraph being traversed
CommandBuffer * getCommandBuffer()
get the current CommandBuffer for the current subgraph being traversed
ref_ptr< RecordedCommandBuffers > recordedCommandBuffers
Container for CommandBuffers that have been recorded in current frame.
Definition: RecordTraversal.h:81
vsg::State is used by vsg::RecordTraversal to manage state stacks, projection and modelview matrices ...
Definition: State.h:228