Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members

FXGLTriangleMesh Class Reference

OpenGL Triangle Mesh Object.

#include <FXGLTriangleMesh.h>

Inheritance diagram for FXGLTriangleMesh:

FXGLShape FXGLObject FXObject List of all members.

Public Methods

 FXGLTriangleMesh (FXfloat x, FXfloat y, FXfloat z, FXint nv, FXfloat *v, FXfloat *n=NULL, FXfloat *c=NULL, FXfloat *t=NULL)
 Construct triangle mesh with nv vertices, and optional normals, colors, and texture coordinates.

 FXGLTriangleMesh (FXfloat x, FXfloat y, FXfloat z, FXint nv, FXfloat *v, FXfloat *n, FXfloat *c, FXfloat *t, const FXMaterial &mtl)
 Construct triangle mesh with nv vertices, and optional normals, colors, and texture coordinates, and surface material.

 FXGLTriangleMesh (const FXGLTriangleMesh &orig)
 Copy constructor.

virtual FXGLObjectcopy ()
 Copy this object.

void setVertexNumber (FXint nvertices)
 Change number of vertices.

FXint getVertexNumber () const
 Get number of vertices.

void setVertexBuffer (FXfloat *vertices)
 Set vertex buffer.

FXfloat * getVertexBuffer () const
 Get vertex buffer.

void setColorBuffer (FXfloat *colors)
 Set color buffer.

FXfloat * getColorBuffer () const
 Get color buffer.

void setNormalBuffer (FXfloat *normals)
 Set normals buffer.

FXfloat * getNormalBuffer () const
 Get normals buffer.

void setTextureCoordBuffer (FXfloat *textures)
 Set texture coordinate buffer.

FXfloat * getTextureCoordBuffer () const
 Get texture coordinate buffer.

virtual void save (FXStream &store) const
 Save to a stream.

virtual void load (FXStream &store)
 Load from a stream.

virtual ~FXGLTriangleMesh ()
 Destructor.