Public Member Functions | Public Attributes

Ovgl::Prop Class Reference

This class represents a prop within a Ovgl::Scene. More...

#include <OvglScene.h>

List of all members.

Public Member Functions

void Update (int bone, Matrix44 *matrix)
void CreateJoints (DWORD bone)
AnimationCreateAnimation (float current, float start, float end)
void setPose (Matrix44 *matrix)
Matrix44 getPose ()
void Release ()

Public Attributes

Scenescene
Meshmesh
std::vector< CMesh * > bones
std::vector< Effect * > subsets
std::vector< Matrix44matrices
std::vector< Joint * > joints
std::vector< Animation * > animations

Detailed Description

This class represents a prop within a Ovgl::Scene.

Props are dynamic objects such as vehicles, rag dolls, and any other objects that react to kinetic forces within the scene.


Member Function Documentation

void Ovgl::Prop::CreateJoints ( DWORD  bone )

This function creates the joints that fuse together bones within the prop. This function will recursivly joints together a parent bone to all child bones and their children until it has gone through the entire tree.

Parameters:
boneIndex of first bone to joint to it's children. This should generally be the meshes root_bone.
Matrix44 Ovgl::Prop::getPose (  )

Returns the current pose of this prop.

void Ovgl::Prop::Release (  )

This function will release control of all memory associated with the prop and it will also remove any reference to it from the scene.

void Ovgl::Prop::setPose ( Matrix44 matrix )

Sets the pose of this prop.

Parameters:
matrixThe matrix which defines the new pose for this prop.
void Ovgl::Prop::Update ( int  bone,
Matrix44 matrix 
)

Used by Ovgl::Scene to update the bone orientations that are displayed to the Ovgl::RenderTarget. This function will recursivly apply the offset of a parent bone to all child bones and their children until it has gone through the entire tree.

Parameters:
boneIndex of the first bone to update. Generally the meshes root_bone.
matrixThis matrix is the amount of offset that is to be applied to the bone.

Member Data Documentation

List of animations affecting this prop.

std::vector<CMesh*> Ovgl::Prop::bones

List of bones that are used to distort the mesh that is displayed for the prop.

std::vector<Joint*> Ovgl::Prop::joints

List of joints that are holding together the bones of this prop.

List of matrices that are taken from the bones and can be passed directly to the shaders to be rendered.

The mesh that is displayed for this prop.

This is a pointer to the scene that this prop was created by and resides in.

std::vector<Effect*> Ovgl::Prop::subsets

List of effects that are used for each subset of the mesh.


The documentation for this class was generated from the following file:
 All Classes Files Functions Variables