WMesh Class Reference

WMesh class. More...

Inheritance diagram for WMesh:

List of all members.

Classes

struct  Material
 Material properties. More...
struct  Mesh
 Mesh struct. More...
struct  Triangle
 Triangle struct. More...
struct  Vertex
 Vertex struct. More...

Public Member Functions

 WMesh (World *world, QString name="unamed", const wMatrix &tm=wMatrix::identity())
 Create a WMesh.
virtual ~WMesh ()
 Destroy this object.
WObjectattachedTo ()
 Return the attached WObject (NULL is there isn't)
void attachTo (WObject *obj)
 Attach to the WObject specified,.
bool loadMS3DModel (QString filename)
 Load the mesh from a MS3D file (MilkShape-3D)
Materialmaterials ()
 Return Materials (for now are ignored during rendering)
int materialsCount ()
 Number of materials.
Meshmeshes ()
 Return Meshes.
int meshesCount ()
 Number of meshes.
Triangletriangles ()
 Return Triangles composing the mesh.
int trianglesCount ()
 Number of triangles.
Vertexvertices ()
 Return Vertices composing the triangles of the mesh.
int verticesCount ()
 Number of vertices.

Detailed Description

WMesh class.

\

Motivation
WMesh represent a 3D shape using a triangle mesh. It is just for graphic purpose, but it is subclass of WObject and it is contained into a World for share it amongs WCameras and for attach it to other object (like iCub's cover)
Description
Warnings
Warnings

Definition at line 41 of file wmesh.h.


Constructor & Destructor Documentation

WMesh ( World world,
QString  name = "unamed",
const wMatrix tm = wMatrix::identity() 
)

Create a WMesh.

Parameters:
worldThe World which object will be inserted
tmrotation and position at the moment of creation

Definition at line 99 of file wmesh.cpp.

~WMesh ( ) [virtual]

Destroy this object.

Definition at line 113 of file wmesh.cpp.


Member Function Documentation

WObject* attachedTo ( ) [inline]

Return the attached WObject (NULL is there isn't)

Definition at line 58 of file wmesh.h.

void attachTo ( WObject obj)

Attach to the WObject specified,.

Note:
when WMesh is attached to a WObject, the WMesh matrix is considered as the offset matrix respect to the matrix of WObject attached

Definition at line 140 of file wmesh.cpp.

Referenced by PhyiCub::PhyiCub().

bool loadMS3DModel ( QString  filename)

Load the mesh from a MS3D file (MilkShape-3D)

Definition at line 144 of file wmesh.cpp.

Referenced by PhyiCub::PhyiCub().

Material* materials ( ) [inline]

Return Materials (for now are ignored during rendering)

Definition at line 94 of file wmesh.h.

int materialsCount ( ) [inline]

Number of materials.

Definition at line 98 of file wmesh.h.

Mesh* meshes ( ) [inline]

Return Meshes.

Definition at line 86 of file wmesh.h.

int meshesCount ( ) [inline]

Number of meshes.

Definition at line 90 of file wmesh.h.

Triangle* triangles ( ) [inline]

Return Triangles composing the mesh.

Definition at line 102 of file wmesh.h.

int trianglesCount ( ) [inline]

Number of triangles.

Definition at line 106 of file wmesh.h.

Vertex* vertices ( ) [inline]

Return Vertices composing the triangles of the mesh.

Definition at line 110 of file wmesh.h.

int verticesCount ( ) [inline]

Number of vertices.

Definition at line 114 of file wmesh.h.


The documentation for this class was generated from the following files: