Go to the source code of this file.
Namespaces | |
namespace | FCDGeometryPolygonsTools |
Defines | |
#define | MAX_BUFFER_COUNT ((uint16)~0) |
MAX_BUFFER_COUNT is the default value to split by when packing vertices and indices. | |
Typedefs | |
typedef fm::map< uint32, UInt32List > | FCDGeometryIndexTranslationMap |
A translation map between old vertex position indices and the new indices. | |
typedef fm::pvector< FCDGeometryIndexTranslationMap > | FCDGeometryIndexTranslationMapList |
A dynamically-sized array of translation maps. | |
typedef fm::vector< UInt32List > | FCDNewIndicesList |
A dynamically-sized array of index lists. | |
Functions | |
FCOLLADA_EXPORT void | FCDGeometryPolygonsTools::Triangulate (FCDGeometryMesh *mesh) |
Triangulates a mesh. | |
FCOLLADA_EXPORT void | FCDGeometryPolygonsTools::Triangulate (FCDGeometryPolygons *polygons, bool recalculate=true) |
Triangulates a polygons set. | |
FCOLLADA_EXPORT void | FCDGeometryPolygonsTools::GenerateTextureTangentBasis (FCDGeometryMesh *mesh, FCDGeometrySource *texcoordSource, bool generateBinormals=true) |
Generates the texture tangents and binormals for a given source of texture coordinates. | |
FCOLLADA_EXPORT void | FCDGeometryPolygonsTools::GenerateUniqueIndices (FCDGeometryMesh *mesh, FCDGeometryPolygons *polygons=NULL, FCDGeometryIndexTranslationMap *translationMap=NULL) |
Prepares the mesh for using its geometry sources in vertex buffers with a unique index buffer. | |
FCOLLADA_EXPORT void | FCDGeometryPolygonsTools::GenerateUniqueIndices (FCDGeometryMesh *mesh, FCDGeometryPolygons *polygonsToProcess, FCDNewIndicesList &outIndices, FCDGeometryIndexTranslationMapList &outTranslationMaps) |
Prepares the mesh for using its geometry sources in vertex buffers with a unique index buffer. | |
FCOLLADA_EXPORT void | FCDGeometryPolygonsTools::ApplyUniqueIndices (float *targData, float *srcData, uint32 stride, const FCDGeometryIndexTranslationMap *translationMap) |
Applies the translation map onto some vertex data. | |
FCOLLADA_EXPORT void | FCDGeometryPolygonsTools::ApplyUniqueIndices (FCDGeometryMesh *targMesh, FCDGeometryMesh *baseMesh, const UInt32List &newIndices, const FCDGeometryIndexTranslationMapList &translationMaps) |
Applies the translation map onto some vertex data. | |
FCOLLADA_EXPORT void | FCDGeometryPolygonsTools::RevertUniqueIndices (const FCDGeometryPolygonsInput &inSrc, FCDGeometryPolygonsInput &outSrc, const FCDGeometryIndexTranslationMap &translationMap) |
Reverts the modifications done when applying the unique index buffer data translation unto some polygons input. | |
FCOLLADA_EXPORT void | FCDGeometryPolygonsTools::PackVertexBufferV3 (uint8 *destBuffer, uint32 destBuffStride, const FCDGeometrySource *source, uint32 vCount, uint16 *vtxPackingMap, const FCDGeometryIndexTranslationMap &translationMap) |
Used to pack a vertex buffer object with 3D float vertex data. | |
FCOLLADA_EXPORT void | FCDGeometryPolygonsTools::PackVertexBufferColor (uint8 *destBuffer, uint32 destBuffStride, const FCDGeometrySource *source, uint32 vCount, uint16 *vtxPackingMap, const FCDGeometryIndexTranslationMap &translationMap) |
Used to pack a vertex buffer object object with 4 bytes color data. | |
FCOLLADA_EXPORT void | FCDGeometryPolygonsTools::PackVertexBufferV2 (uint8 *destBuffer, uint32 destBuffStride, const FCDGeometrySource *source, uint32 vCount, uint16 *vtxPackingMap, const FCDGeometryIndexTranslationMap &translationMap) |
Used to pack a vertex buffer object object with 2D float vertex data. | |
FCOLLADA_EXPORT uint16 | FCDGeometryPolygonsTools::GenerateVertexPackingMap (size_t maxIndex, size_t maxIndices, size_t maxVertices, const uint32 *inIndices, uint16 *outIndices, UInt16List *outPackingMap, uint16 *outNVertices=NULL) |
Generates a packing map for a mesh' given vertex data. | |
FCOLLADA_EXPORT uint32 | FCDGeometryPolygonsTools::FindLargestUniqueIndex (const FCDGeometryIndexTranslationMap &translationMap) |
Retrieves the largest unique index within a given translation map. | |
FCOLLADA_EXPORT void | FCDGeometryPolygonsTools::FitIndexBuffers (FCDGeometryMesh *mesh, size_t maximumIndexCount) |
Splits the mesh's polygons sets to ensure that none of them have more than a given number of indices within their index buffers. | |
FCOLLADA_EXPORT void | FCDGeometryPolygonsTools::ReverseNormals (FCDGeometryMesh *mesh) |
Reverses all the normals of a mesh. |
|
MAX_BUFFER_COUNT is the default value to split by when packing vertices and indices. It represents the usual upper limit of video cards on buffer submission size |
|
A translation map between old vertex position indices and the new indices. It is generated in the FCDGeometryPolygonsTools::GenerateUniqueIndices function. |