70 bool cull()
const {
return _cull; }
71 void setCull(
const bool value) { _cull = value; }
76 uint32_t
mask()
const {
return _mask; }
77 void setMask(
const uint32_t value) { _mask = value; }
82 void setInstancing(
const std::shared_ptr<VertexBuffer>& vertexBuffer,
int count)
84 _instancingData.vertexBuffer = vertexBuffer;
85 _instancingData.count = count;
93 const std::shared_ptr<VertexBuffer>& compactedVB,
94 void* indirectArgs,
int slot = 0)
96 _instancingData.compactedVertexBuffer = compactedVB;
97 _instancingData.indirectArgsBuffer = indirectArgs;
98 _instancingData.indirectSlot = slot;
131 Mesh* _mesh =
nullptr;
137 bool _updateAabb =
true;
141 int _aabbMeshVer = -1;
145 InstancingData _instancingData;
147 bool _castShadow =
true;
148 bool _receiveShadow =
true;
150 bool _visibleThisFrame =
false;
154 int _batchGroupId = -1;
155 bool _visible =
true;
156 bool _dynamicBatch =
false;
Axis-Aligned Bounding Box defined by center and half-extents.
Hierarchical scene graph node with local/world transforms and parent-child relationships.
Base class for GPU materials — owns uniform data, texture bindings, blend/depth state,...
GPU-resident geometry defined by vertex/index buffers and one or more Primitives.
void setReceiveShadow(const bool value)
void setBatchGroupId(int id)
int instancingCount() const
bool isDynamicBatch() const
void setDynamicBatch(bool v)
void setCustomAabb(const BoundingBox &aabb)
void setCull(const bool value)
SkinBatchInstance * skinBatchInstance() const
Material * material() const
bool receiveShadow() const
void setMask(const uint32_t value)
const InstancingData & instancingData() const
bool visibleThisFrame() const
void setInstancing(const std::shared_ptr< VertexBuffer > &vertexBuffer, int count)
void setIndirectInstancing(const std::shared_ptr< VertexBuffer > &compactedVB, void *indirectArgs, int slot=0)
void setSkinBatchInstance(SkinBatchInstance *sbi)
MeshInstance(Mesh *mesh, Material *material, GraphNode *node=nullptr)
void setVisibleThisFrame(const bool value)
void setCastShadow(const bool value)
constexpr uint32_t MASK_AFFECT_DYNAMIC
std::shared_ptr< VertexBuffer > vertexBuffer
void * indirectArgsBuffer
std::shared_ptr< VertexBuffer > compactedVertexBuffer