#include <lugre_meshbuffer.h>

Public Member Functions | |
| cBufferedSubMesh () | |
| int | GetVertexCount () |
| int | GetIndexCount () |
| bool | GetUsesShared () |
| unsigned int * | GetIndexData () |
| std::string & | GetMatName () |
| Ogre::MaterialPtr & | GetMat () |
| std::string & | GetFormatHash () |
| std::string & | GetFormatHashWithColour () |
| added diffuse colour if needed | |
| cBufferedVertexData & | GetBufferedVertexData () |
| void | SetFromSubMesh (cBufferedMesh *pParent, Ogre::SubMesh &pSubMesh) |
| init, don't call more than once | |
| void | SetMatName (const char *szMatName) |
| void | TransformTexCoords (const float u0, const float v0, const float u1, const float v1) |
Private Attributes | |
| cBufferedVertexData | mBufferedVertexData |
| cBufferedMesh * | mpParent |
| std::vector< unsigned int > | mIndexData |
| std::string | msMatName |
| Ogre::MaterialPtr | mpMat |
| std::string | msFormatHash |
| std::string | msFormatHashWithColour |
| bool | mbUseSharedVertexData |
Definition at line 122 of file lugre_meshbuffer.h.
| Lugre::cBufferedSubMesh::cBufferedSubMesh | ( | ) |
Definition at line 170 of file lugre_meshbuffer.cpp.
| int Lugre::cBufferedSubMesh::GetVertexCount | ( | ) | [inline] |
Definition at line 125 of file lugre_meshbuffer.h.
References Lugre::cBufferedVertexData::GetVertexCount(), and mBufferedVertexData.
Referenced by Lugre::cFastBatch::cSubBatch::AddInstance(), and TransformTexCoords().
| int Lugre::cBufferedSubMesh::GetIndexCount | ( | ) | [inline] |
Definition at line 126 of file lugre_meshbuffer.h.
References mIndexData.
Referenced by Lugre::cFastBatch::cSubBatch::AddInstance(), Lugre::cFastBatch::cSubBatch::Build(), and Lugre::cBufferedMesh::RayPick().
| bool Lugre::cBufferedSubMesh::GetUsesShared | ( | ) | [inline] |
Definition at line 127 of file lugre_meshbuffer.h.
References mbUseSharedVertexData.
Referenced by Lugre::cFastBatch::AddMesh(), Lugre::cBufferedMesh::RayPick(), Lugre::cBufferedMesh::SetFromMesh(), and TransformTexCoords().
| unsigned int* Lugre::cBufferedSubMesh::GetIndexData | ( | ) | [inline] |
Definition at line 128 of file lugre_meshbuffer.h.
References mIndexData.
Referenced by Lugre::cFastBatch::cSubBatch::Build(), and Lugre::cBufferedMesh::RayPick().
| std::string& Lugre::cBufferedSubMesh::GetMatName | ( | ) | [inline] |
| Ogre::MaterialPtr& Lugre::cBufferedSubMesh::GetMat | ( | ) | [inline] |
Definition at line 130 of file lugre_meshbuffer.h.
References mpMat.
Referenced by Lugre::cFastBatch::cSubBatch::cSubBatch().
| std::string& Lugre::cBufferedSubMesh::GetFormatHash | ( | ) | [inline] |
Definition at line 131 of file lugre_meshbuffer.h.
References msFormatHash.
Referenced by Lugre::cFastBatch::AddMesh().
| std::string& Lugre::cBufferedSubMesh::GetFormatHashWithColour | ( | ) | [inline] |
added diffuse colour if needed
Definition at line 132 of file lugre_meshbuffer.h.
References msFormatHashWithColour.
Referenced by Lugre::cFastBatch::AddMesh().
| cBufferedVertexData& Lugre::cBufferedSubMesh::GetBufferedVertexData | ( | ) | [inline] |
Definition at line 133 of file lugre_meshbuffer.h.
References mBufferedVertexData.
Referenced by Lugre::cFastBatch::cSubBatch::Build(), Lugre::cFastBatch::cSubBatch::cSubBatch(), Lugre::cBufferedMesh::RayPick(), and Lugre::cBufferedMesh::SetFromMesh().
| void Lugre::cBufferedSubMesh::SetFromSubMesh | ( | cBufferedMesh * | pParent, | |
| Ogre::SubMesh & | pSubMesh | |||
| ) |
init, don't call more than once
Definition at line 190 of file lugre_meshbuffer.cpp.
References DEBUG_MESHBUFFER, Lugre::cBufferedVertexData::GetVertexDecl(), mBufferedVertexData, mbUseSharedVertexData, mIndexData, mpParent, msFormatHash, msFormatHashWithColour, msMatName, Lugre::cBufferedVertexData::SetFromVertexData(), and SetMatName().
Referenced by Lugre::cBufferedMesh::SetFromMesh().
| void Lugre::cBufferedSubMesh::SetMatName | ( | const char * | szMatName | ) |
asigns the specified material name interesting for texatlas
Definition at line 183 of file lugre_meshbuffer.cpp.
References mpMat, and msMatName.
Referenced by SetFromSubMesh().
| void Lugre::cBufferedSubMesh::TransformTexCoords | ( | const float | u0, | |
| const float | v0, | |||
| const float | u1, | |||
| const float | v1 | |||
| ) |
changes texturecoordinates : clamps them in the range [0,1],[0,1] and maps that range to [u0,u1],[v0,v1] interesting for texatlas
Definition at line 172 of file lugre_meshbuffer.cpp.
References GetUsesShared(), GetVertexCount(), Lugre::cBufferedVertexData::GetVertexTexCoord(), mBufferedVertexData, msMatName, Lugre::mymax(), and Lugre::mymin().
Definition at line 147 of file lugre_meshbuffer.h.
Referenced by GetBufferedVertexData(), GetVertexCount(), SetFromSubMesh(), and TransformTexCoords().
cBufferedMesh* Lugre::cBufferedSubMesh::mpParent [private] |
std::vector<unsigned int> Lugre::cBufferedSubMesh::mIndexData [private] |
Definition at line 149 of file lugre_meshbuffer.h.
Referenced by GetIndexCount(), GetIndexData(), and SetFromSubMesh().
std::string Lugre::cBufferedSubMesh::msMatName [private] |
Definition at line 150 of file lugre_meshbuffer.h.
Referenced by GetMatName(), SetFromSubMesh(), SetMatName(), and TransformTexCoords().
Ogre::MaterialPtr Lugre::cBufferedSubMesh::mpMat [private] |
std::string Lugre::cBufferedSubMesh::msFormatHash [private] |
Definition at line 152 of file lugre_meshbuffer.h.
Referenced by GetFormatHash(), and SetFromSubMesh().
std::string Lugre::cBufferedSubMesh::msFormatHashWithColour [private] |
Definition at line 153 of file lugre_meshbuffer.h.
Referenced by GetFormatHashWithColour(), and SetFromSubMesh().
bool Lugre::cBufferedSubMesh::mbUseSharedVertexData [private] |
Definition at line 154 of file lugre_meshbuffer.h.
Referenced by GetUsesShared(), and SetFromSubMesh().
1.5.6