This class represents a prop within a Ovgl::Scene. More...
#include <OvglScene.h>
Public Member Functions | |
| void | Update (int bone, Matrix44 *matrix) |
| void | CreateJoints (DWORD bone) |
| Animation * | CreateAnimation (float current, float start, float end) |
| void | setPose (Matrix44 *matrix) |
| Matrix44 | getPose () |
| void | Release () |
Public Attributes | |
| Scene * | scene |
| Mesh * | mesh |
| std::vector< CMesh * > | bones |
| std::vector< Effect * > | subsets |
| std::vector< Matrix44 > | matrices |
| std::vector< Joint * > | joints |
| std::vector< Animation * > | animations |
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.
| 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.
| bone | Index 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.
| matrix | The 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.
| bone | Index of the first bone to update. Generally the meshes root_bone. |
| matrix | This matrix is the amount of offset that is to be applied to the bone. |
| std::vector<Animation*> Ovgl::Prop::animations |
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.
| std::vector<Matrix44> Ovgl::Prop::matrices |
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.
1.7.2