PixelLightAPI
.
|
Abstract renderer index buffer (IBO) resource. More...
#include <IndexBuffer.h>
Public Types | |
enum | EType { UInt = 0, UShort = 1, UByte = 2 } |
Vertex index types. More... | |
Public Member Functions | |
virtual PLRENDERER_API | ~IndexBuffer () |
Destructor. | |
EType | GetElementType () const |
Returns the type of the buffer elements. | |
bool | SetElementType (EType nType=UShort) |
Sets the type of the buffer elements. | |
bool | SetElementTypeByMaximumIndex (PLCore::uint32 nMaximumIndex) |
Sets the type of the buffer elements automatically by using a given maximum vertex index. | |
PLRENDERER_API IndexBuffer & | operator= (const IndexBuffer &cSource) |
Copy operator. | |
PLRENDERER_API PLCore::uint32 | GetData (PLCore::uint32 nIndex) |
Returns the data of the index buffer. | |
PLRENDERER_API bool | SetData (PLCore::uint32 nIndex, PLCore::uint32 nData) |
Sets the data of the index buffer. | |
virtual PLRENDERER_API void * | GetData () override |
Returns the buffer data. | |
Static Public Attributes | |
static const PLCore::uint32 | MaxVertexIndexUShort = 65535 |
static const PLCore::uint32 | MaxVertexIndexUByte = 255 |
Protected Member Functions | |
PLRENDERER_API | IndexBuffer (Renderer &cRenderer) |
Constructor. | |
Protected Attributes | |
EType | m_nElementType |
Abstract renderer index buffer (IBO) resource.
Vertex index types.
UInt |
Unsigned int (may not be supported by each API) |
UShort |
Unsigned short (default) |
UByte |
Unsigned byte (may not be supported by each API) |
Reimplemented from PLRenderer::Resource.
virtual PLRENDERER_API PLRenderer::IndexBuffer::~IndexBuffer | ( | ) | [virtual] |
Destructor.
PLRENDERER_API PLRenderer::IndexBuffer::IndexBuffer | ( | Renderer & | cRenderer | ) | [protected] |
Constructor.
[in] | cRenderer | Owner renderer |
IndexBuffer::EType PLRenderer::IndexBuffer::GetElementType | ( | ) | const [inline] |
Returns the type of the buffer elements.
bool PLRenderer::IndexBuffer::SetElementType | ( | EType | nType = UShort | ) | [inline] |
Sets the type of the buffer elements.
[in] | nType | The type of the buffer elements |
bool PLRenderer::IndexBuffer::SetElementTypeByMaximumIndex | ( | PLCore::uint32 | nMaximumIndex | ) | [inline] |
Sets the type of the buffer elements automatically by using a given maximum vertex index.
[in] | nMaximumIndex | Maximum vertex index |
PLRENDERER_API IndexBuffer& PLRenderer::IndexBuffer::operator= | ( | const IndexBuffer & | cSource | ) |
Copy operator.
[in] | cSource | Source to copy from |
PLRENDERER_API PLCore::uint32 PLRenderer::IndexBuffer::GetData | ( | PLCore::uint32 | nIndex | ) |
Returns the data of the index buffer.
[in] | nIndex | Index index |
PLRENDERER_API bool PLRenderer::IndexBuffer::SetData | ( | PLCore::uint32 | nIndex, |
PLCore::uint32 | nData | ||
) |
Sets the data of the index buffer.
[in] | nIndex | Index index |
[in] | nData | Data to set |
virtual PLRENDERER_API void* PLRenderer::IndexBuffer::GetData | ( | ) | [override, virtual] |
Returns the buffer data.
Implements PLRenderer::Buffer.
const PLCore::uint32 PLRenderer::IndexBuffer::MaxVertexIndexUShort = 65535 [static] |
Maximum vertex index which can be used if UShort is used as index buffer type
const PLCore::uint32 PLRenderer::IndexBuffer::MaxVertexIndexUByte = 255 [static] |
Maximum vertex index which can be used if UByte is used as index buffer type
EType PLRenderer::IndexBuffer::m_nElementType [protected] |
Element type
|