CrystalSpace

Public API Reference

iGeneralMeshState Struct Reference
[Mesh plugins]

This interface describes the API for the general mesh object. More...

#include <imesh/genmesh.h>

Inheritance diagram for iGeneralMeshState:

Inheritance graph
[legend]
List of all members.

Public Member Functions

virtual iGenMeshAnimationControlGetAnimationControl () const =0
 Get the current animation control for this object.
virtual void SetAnimationControl (iGenMeshAnimationControl *anim_ctrl)=0
 Set the animation control to use for this mesh object.
Legacy submesh support
virtual void AddSubMesh (unsigned int *triangles, int tricount, iMaterialWrapper *material, uint mixmode)=0
 Add a submesh to this object.
virtual void AddSubMesh (unsigned int *triangles, int tricount, iMaterialWrapper *material)=0
 Add a submesh to this object.
SubMesh handling
virtual iGeneralMeshSubMeshFindSubMesh (const char *name) const =0
 Find the index of a submesh.

Detailed Description

This interface describes the API for the general mesh object.

Main creators of instances implementing this interface:

Main ways to get pointers to this interface:

Main users of this interface:

Definition at line 150 of file genmesh.h.


Member Function Documentation

virtual void iGeneralMeshState::AddSubMesh ( unsigned int *  triangles,
int  tricount,
iMaterialWrapper material,
uint  mixmode 
) [pure virtual]

Add a submesh to this object.

A submesh is a subset of the mesh triangles rendered with a certain material. When a mesh has one or more submeshes, only submeshes are drawn and not original geometry. That means submeshes should cover all original triangles to avoid holes in the mesh. triangles is an array of indices into the factory triangle list tricount is the number of triangles in "triangles" material is a material to assign to the mesh Note! SubMeshes added to an instance of a genmesh will override the submeshes from the factory (i.e. the submeshes of the factory will be completely ignored as soon as the instance has submeshes). This version overrides the parent mixmode.

Deprecated:
Use AddSubMesh from iGeneralFactoryState instead

virtual void iGeneralMeshState::AddSubMesh ( unsigned int *  triangles,
int  tricount,
iMaterialWrapper material 
) [pure virtual]

Add a submesh to this object.

A submesh is a subset of the mesh triangles rendered with a certain material. When a mesh has one or more submeshes, only submeshes are drawn and not original geometry. That means submeshes should cover all original triangles to avoid holes in the mesh. triangles is an array of indices into the factory triangle list tricount is the number of triangles in "triangles" material is a material to assign to the mesh Note! SubMeshes added to an instance of a genmesh will override the submeshes from the factory (i.e. the submeshes of the factory will be completely ignored as soon as the instance has submeshes).

Deprecated:
Use AddSubMesh from iGeneralFactoryState instead

virtual iGeneralMeshSubMesh* iGeneralMeshState::FindSubMesh ( const char *  name  )  const [pure virtual]

Find the index of a submesh.

The index can be used with DeleteSubMesh() and the GetSubMesh...() methods. Returns 0 if the submesh was not found.

The returned interface can be used for limited per-object variation of the submeshes as defined in the factory. Currently the following aspects can be overridden:

virtual iGenMeshAnimationControl* iGeneralMeshState::GetAnimationControl (  )  const [pure virtual]

Get the current animation control for this object.

virtual void iGeneralMeshState::SetAnimationControl ( iGenMeshAnimationControl anim_ctrl  )  [pure virtual]

Set the animation control to use for this mesh object.

See iGenMeshAnimationControl for more information.


The documentation for this struct was generated from the following file:
Generated for Crystal Space by doxygen 1.4.7