OGRE 2.1
Object-Oriented Graphics Rendering Engine
Loading...
Searching...
No Matches
Ogre::VertexElement2 Struct Reference

#include <OgreVertexBufferPacked.h>

Public Member Functions

 VertexElement2 (VertexElementType type, VertexElementSemantic semantic)
 
bool operator< (const VertexElement2 &_r) const
 Warning: Beware a VertexElement2Vec shouldn't be sorted.
 
bool operator== (const VertexElement2 _r) const
 
bool operator== (VertexElementSemantic semantic) const
 

Public Attributes

uint32 mInstancingStepRate
 The number of instances to draw using the same per-instance data before advancing in the buffer by one element.
 
VertexElementSemantic mSemantic
 The meaning of the element.
 
VertexElementType mType
 The type of element.
 

Constructor & Destructor Documentation

◆ VertexElement2()

Ogre::VertexElement2::VertexElement2 ( VertexElementType  type,
VertexElementSemantic  semantic 
)
inline

Member Function Documentation

◆ operator<()

bool Ogre::VertexElement2::operator< ( const VertexElement2 _r) const
inline

Warning: Beware a VertexElement2Vec shouldn't be sorted.

The order in which they're pushed into the vector defines the offsets in the vertex buffer. Altering the order would cause the GPU to to read garbage when trying to interpret the vertex buffer This operator exists because it's useful when implementing a '<' operator in other structs that contain VertexElement2Vecs (see HlmsPso)

◆ operator==() [1/2]

bool Ogre::VertexElement2::operator== ( const VertexElement2  _r) const
inline

References mInstancingStepRate, mSemantic, and mType.

◆ operator==() [2/2]

bool Ogre::VertexElement2::operator== ( VertexElementSemantic  semantic) const
inline

References mSemantic.

Member Data Documentation

◆ mInstancingStepRate

uint32 Ogre::VertexElement2::mInstancingStepRate

The number of instances to draw using the same per-instance data before advancing in the buffer by one element.

This value must be 0 for an element that contains per-vertex data

Referenced by operator==().

◆ mSemantic

VertexElementSemantic Ogre::VertexElement2::mSemantic

The meaning of the element.

Referenced by operator==(), and operator==().

◆ mType

VertexElementType Ogre::VertexElement2::mType

The type of element.

Referenced by operator==().


The documentation for this struct was generated from the following file: