#include <ecmesh.h>
Public Member Functions | |
Mesh (const char *a_sID, Buffer *a_pVertexBuffer, unsigned int a_nVertexOffset, unsigned int a_nVertexCount, Buffer *a_pUVBuffer, unsigned int a_nUVOffset, unsigned int a_nUVCount, Buffer *a_pIndexBuffer, unsigned int a_nIndexOffset, unsigned int a_nTriangleCount, Scene *a_pScene, Material *a_pMaterial, Matrix *a_pMatrix=NULL) | |
Creates a new mesh object The vertex offset and vertex count numbers are applied to the UV buffer as well, meaning that the vertex buffer and the uv buffer MUST have a one-to-one correspondance. | |
YRTriangleObject * | GetYRTrimesh () |
Returns the actual yafaray mesh. | |
virtual PYOBJECT | PyAsString () |
Python text representation method This function must be implemented by all children. | |
Static Public Member Functions | |
static bool | PyTypeCheck (PYOBJECT a_pObject) |
Python type check Verifies that the provided python object encapsulates a mesh. | |
Protected Member Functions | |
~Mesh () | |
Only we can destroy ourselves. | |
virtual void | DeleteObject () |
Child message hook for reference-count based destruction. |
Defines the base mesh object.
Definition at line 50 of file ecmesh.h.
Mesh::Mesh | ( | const char * | a_sID, | |
Buffer * | a_pVertexBuffer, | |||
unsigned int | a_nVertexOffset, | |||
unsigned int | a_nVertexCount, | |||
Buffer * | a_pUVBuffer, | |||
unsigned int | a_nUVOffset, | |||
unsigned int | a_nUVCount, | |||
Buffer * | a_pIndexBuffer, | |||
unsigned int | a_nIndexOffset, | |||
unsigned int | a_nTriangleCount, | |||
Scene * | a_pScene, | |||
Material * | a_pMaterial, | |||
Matrix * | a_pMatrix = NULL | |||
) |
Creates a new mesh object The vertex offset and vertex count numbers are applied to the UV buffer as well, meaning that the vertex buffer and the uv buffer MUST have a one-to-one correspondance.
a_sID | Unique mesh ID | |
a_pVertexBuffer | A buffer containing all required vertices | |
a_nVertexOffset | Offset (in number of vertices) for use when reading from the vertex buffer | |
a_nVertexCount | Number of vertices to read from the vertex buffer | |
a_pUVBuffer | A buffer containing a set of UV coordinates per vertex | |
a_nUVOffset | Offset (in number of UV pairs) for accessing our uv buffer | |
a_nUVCount | Number of UV components to read from the buffer | |
a_pIndexBuffer | A buffer for a triangle list, containing 6 indexes per face (3 vert + 3 uv ) | |
a_nIndexOffset | Offset (in number of components) into the index buffer | |
a_nTriangleCount | Number of triangles to include. This determines the number of indexes to read (6 per triangle) | |
a_pScene | A valid scene for this mesh to live in | |
a_pMaterial | A valid material for this mesh to have | |
a_pMatrix | An optional transformation matrix to apply over the vertex buffer |
virtual void Mesh::DeleteObject | ( | ) | [protected, virtual] |
Child message hook for reference-count based destruction.
The child class is responsible for deleting any instance to which this this function is called.
Reimplemented from EclipseObject.
virtual PYOBJECT Mesh::PyAsString | ( | ) | [virtual] |
Python text representation method This function must be implemented by all children.
Reimplemented from EclipseObject.
static bool Mesh::PyTypeCheck | ( | PYOBJECT | a_pObject | ) | [static] |
Python type check Verifies that the provided python object encapsulates a mesh.
Reimplemented from EclipseObject.