Compiles the render information for an Entity to use within a RenderQueue. More...
Public Member Functions | |
EntityRenderInfo () noexcept | |
EntityRenderInfo (const EntityRenderInfo &other) noexcept | |
EntityRenderInfo (EntityRenderInfo &&other) noexcept | |
EntityRenderInfo (Mesh *mesh, Shader *shader) noexcept | |
virtual | ~EntityRenderInfo () |
EntityRenderInfoSlot * | getSlot (unsigned int index) const |
const nkMemory::BufferCast< EntityRenderInfoSlot * > & | getSlots () const |
Entity * | getParentEntity () const |
EntityRenderInfoSlot * | addSlot (const EntityRenderInfoSlot &infoSlot=EntityRenderInfoSlot()) |
void | eraseSlot (unsigned int index) |
EntityRenderInfo & | operator= (const EntityRenderInfo &other) noexcept |
EntityRenderInfo & | operator= (EntityRenderInfo &&other) noexcept |
virtual void | exportClassToTree (nkExport::Node *rootNode) override |
virtual void | importClassFromTree (nkExport::Node *rootNode) override |
Public Member Functions inherited from nkExport::Exportable | |
Exportable () noexcept | |
virtual | ~Exportable () |
Compiles the render information for an Entity to use within a RenderQueue.
This class is the starting point, where all slots and lods will be provided. A high level overview of the hierarchy is as such :
Info
For the default render strategy, each slot will be questioned for the LOD to render depending on its parameters, for a given pass. It is possible to add as many slots as wanted to the information, and each can have any amount of LOD as required.
|
noexcept |
Default constructor.
|
noexcept |
Copy constructor.
other | The render information to copy from. |
|
noexcept |
Move constructor.
other | The render information to move. |
Legacy convenience constructor. This constructor mimicks what was possible before to a certain degree, by quickly creating a slot and a LOD using both parameters provided. This LOD will be used in all cases.
mesh | The mesh to use. |
shader | The shader to use. |
|
virtual |
Destructor.
EntityRenderInfoSlot* nkGraphics::EntityRenderInfo::getSlot | ( | unsigned int | index | ) | const |
index | The index of the slot to retrieve. |
const nkMemory::BufferCast<EntityRenderInfoSlot*>& nkGraphics::EntityRenderInfo::getSlots | ( | ) | const |
Entity* nkGraphics::EntityRenderInfo::getParentEntity | ( | ) | const |
EntityRenderInfoSlot* nkGraphics::EntityRenderInfo::addSlot | ( | const EntityRenderInfoSlot & | infoSlot = EntityRenderInfoSlot() | ) |
Adds a slot to the information.
infoSlot | The slot to copy from, if required. |
void nkGraphics::EntityRenderInfo::eraseSlot | ( | unsigned int | index | ) |
Erases an existing slot.
index | The index of the slot to erase. |
|
noexcept |
Copy assignment operator.
other | The information to copy from. |
|
noexcept |
Move assignment operator.
other | The information to move from. |
|
overridevirtual |
Exports an item into a tree describing its structure and its data.
rootNode | The node into which the object has to write its related information. |
Implements nkExport::Exportable.
|
overridevirtual |
Imports information from a tree which is supposed to describe its structure and data.
rootNode | The root node of the tree holding the information. |
Implements nkExport::Exportable.