SharedVertexBufferclass encapsulates a reference-counted vertex buffer.
class SharedVertexBuffer : public VertexBuffer
||Retains a reference to a shared vertex buffer.|
||Releases a reference to a shared vertex buffer.|
||The vertex buffer flags. See the |
SharedVertexBufferclass is a vertex buffer that has a reference count so that it can safely be shared among multiple renderable objects. A shared vertex buffer is typically used when some vertex attribute or index data is identical for multiple instances of a renderable object of some kind.
When a shared vertex buffer object is first constructed, there are no references to it, and its reference count is zero. The
SharedVertexBuffer::Retainfunction is used to add a new reference to the vertex buffer, and the
SharedVertexBuffer::Releasefunction is used to remove a reference. The
Retainfunction is typically called in the constructor for some class, and the
Releasefunction is typically called in its destructor.