#include <hlms.h>
◆ ConstBufferPackedVec
◆ SharedHelperForHlms()
| SharedHelperForHlms::SharedHelperForHlms |
( |
| ) |
|
|
protected |
◆ ~SharedHelperForHlms()
| SharedHelperForHlms::~SharedHelperForHlms |
( |
| ) |
|
|
protected |
◆ bindObjectDataBuffer()
| void SharedHelperForHlms::bindObjectDataBuffer |
( |
Ogre::CommandBuffer * |
commandBuffer, |
|
|
uint16_t |
perObjectDataBufferSlot |
|
) |
| |
|
protected |
Binds currPerObjectDataBuffer to the right slot.
Does nothing if it's nullptr.
- Parameters
-
| commandBuffer | Cmd buffer to bind to. |
| perObjectDataBufferSlot | Slot to bind the buffer to. |
◆ mapObjectDataBufferFor()
| float * SharedHelperForHlms::mapObjectDataBufferFor |
( |
uint32_t |
instanceIdx, |
|
|
Ogre::CommandBuffer * |
commandBuffer, |
|
|
Ogre::VaoManager * |
vaoManager, |
|
|
const ConstBufferPackedVec & |
constBuffers, |
|
|
uint32_t |
currConstBufferIdx, |
|
|
uint32_t * |
startMappedConstBuffer, |
|
|
uint16_t |
perObjectDataBufferSlot, |
|
|
uint16_t |
element_count |
|
) |
| |
|
protected |
- Parameters
-
| instanceIdx | The index of the instance to write to. |
| commandBuffer | Command buffer to bind our new buffer if we create one. |
| vaoManager | VaoManager to create new ConstBufferPacked. |
| constBuffers | Reference to mConstBuffers so we can tell if we need to bind a new const buffer. |
| currConstBufferIdx | Value of mCurrentConstBuffer so we can tell if we need to bind a new const buffer. |
| startMappedConstBuffer | Value of mStartMappedConstBuffer for validation (to ensure our implementation isn't out of sync with OgreNext's). |
| perObjectDataBufferSlot | See mapConstBuffer(). |
- Returns
◆ unmapObjectDataBuffer()
| void SharedHelperForHlms::unmapObjectDataBuffer |
( |
| ) |
|
|
protected |
Unmaps the current buffer holding per-object data from memory.
◆ mCurrPerObjectDataBuffer
| Ogre::ConstBufferPacked* ogre_nullable SharedHelperForHlms::mCurrPerObjectDataBuffer |
|
protected |
The buffer currently use. Can be nullptr. It is contained in mPerObjectDataBuffers.
◆ mCurrPerObjectDataPtr
| float* ogre_nullable SharedHelperForHlms::mCurrPerObjectDataPtr |
|
protected |
The mapped contents of currPerObjectDataBuffer.
◆ mLastMainConstBuffer
| Ogre::ConstBufferPacked* ogre_nullable SharedHelperForHlms::mLastMainConstBuffer |
|
protected |
The last content of mCurrentConstBuffer.
If it changes we need a new mCurrPerObjectDataBuffer too (because drawId will be reset from 0).
◆ mOwnVaoManager
| Ogre::VaoManager* ogre_nullable SharedHelperForHlms::mOwnVaoManager |
|
protected |
Pointer to Ogre's VAO manager. Used here for destroying const buffers.
◆ mPerObjectDataBuffers
Vector of buffers holding per-object data.
When one runs out, we push a new one. On the next frame we reuse them all from 0.
The documentation for this class was generated from the following files: