#include <Model.h>
Public Member Functions | |
| Model () | |
| virtual | ~Model () |
| Vector & | getMin () |
| Vector & | getMax () |
| std::vector< Mesh * > & | getMeshes () |
| std::vector < BoneType * > & | getBaseBoneTypes () |
| std::vector< Bone * > & | getBones () |
| int | getNumberTriangles () |
| int | getStartFrame () |
| int | getTotalFrames () |
| void | setup () |
| void | addMesh (Mesh *mesh) |
| void | addBone (Bone *bone) |
| void | setStartFrame (int frame) |
| void | setTotalFrames (int frames) |
Protected Member Functions | |
| void | centre () |
| void | setupBones () |
| void | setupColor () |
Protected Attributes | |
| std::vector< Mesh * > | meshes_ |
| std::vector< Bone * > | bones_ |
| std::vector< BoneType * > | baseBoneTypes_ |
| Vector | min_ |
| Vector | max_ |
| int | startFrame_ |
| int | totalFrames_ |
Definition at line 27 of file Model.h.
| Model::~Model | ( | ) | [virtual] |
| Vector& Model::getMin | ( | ) | [inline] |
Definition at line 33 of file Model.h.
References min_.
Referenced by ASEModelFactory::calculateTexCoords(), TreeModelFactory::createModel(), TargetDefinition::createTarget(), ShotBounce::draw(), ModelRendererMesh::drawBottomAligned(), MissileMesh::MissileMesh(), and TankMesh::setupTankMesh().
| Vector& Model::getMax | ( | ) | [inline] |
Definition at line 34 of file Model.h.
References max_.
Referenced by ASEModelFactory::calculateTexCoords(), TreeModelFactory::createModel(), TargetDefinition::createTarget(), MissileMesh::MissileMesh(), and TankMesh::setupTankMesh().
| std::vector<Mesh *>& Model::getMeshes | ( | ) | [inline] |
Definition at line 35 of file Model.h.
References meshes_.
Referenced by ASEModelFactory::calculateTexCoords(), ModelRendererMesh::draw(), ASEModelFactory::getCurrentMesh(), MSModelFactory::loadFile(), MissileMesh::MissileMesh(), ModelRendererMesh::setup(), and TankMesh::setupTankMesh().
| std::vector<BoneType *>& Model::getBaseBoneTypes | ( | ) | [inline] |
Definition at line 36 of file Model.h.
References baseBoneTypes_.
Referenced by ModelRendererMesh::setup().
| std::vector<Bone *>& Model::getBones | ( | ) | [inline] |
Definition at line 37 of file Model.h.
References bones_.
Referenced by ModelRendererMesh::drawVerts().
| int Model::getNumberTriangles | ( | ) |
Definition at line 82 of file Model.cpp.
References Mesh::getFaces(), int(), and meshes_.
Referenced by TankMesh::getNoTris(), and TankModelStore::loadTankMeshes().
| int Model::getStartFrame | ( | ) | [inline] |
Definition at line 39 of file Model.h.
References startFrame_.
Referenced by ModelRendererMesh::drawMesh(), and ModelRendererSimulator::ModelRendererSimulator().
| int Model::getTotalFrames | ( | ) | [inline] |
Definition at line 40 of file Model.h.
References totalFrames_.
Referenced by ModelRendererMesh::drawMesh(), ModelRendererSimulator::ModelRendererSimulator(), and ModelRendererMesh::setup().
| void Model::setup | ( | ) |
Definition at line 96 of file Model.cpp.
References centre(), setupBones(), and setupColor().
Referenced by MSModelFactory::createModel(), and ASEModelFactory::createModel().
| void Model::addMesh | ( | Mesh * | mesh | ) | [inline] |
Definition at line 44 of file Model.h.
References meshes_.
Referenced by ASEModelFactory::addMesh(), and MSModelFactory::loadFile().
| void Model::addBone | ( | Bone * | bone | ) | [inline] |
| void Model::setStartFrame | ( | int | frame | ) | [inline] |
Definition at line 46 of file Model.h.
References startFrame_.
Referenced by MSModelFactory::loadFile().
| void Model::setTotalFrames | ( | int | frames | ) | [inline] |
Definition at line 47 of file Model.h.
References totalFrames_.
Referenced by MSModelFactory::loadFile().
| void Model::centre | ( | ) | [protected] |
| void Model::setupBones | ( | ) | [protected] |
Definition at line 140 of file Model.cpp.
References BoneType::absolute_, ModelMaths::angleMatrix(), baseBoneTypes_, Vertex::boneIndex, bones_, ModelMaths::concatTransforms(), DIALOG_ASSERT, BoneType::final_, Bone::getName(), Bone::getParentName(), Bone::getPosition(), Mesh::getReferencesBones(), Bone::getRotation(), Mesh::getVertex(), Mesh::getVertexes(), meshes_, BoneType::parent_, PI, Vertex::position, BoneType::relative_, LangStringUtil::strcmp(), and ModelMaths::vectorIRotate().
Referenced by setup().
| void Model::setupColor | ( | ) | [protected] |
Definition at line 103 of file Model.cpp.
References Vector::dotP(), Mesh::getFaces(), Mesh::getVertex(), Vertex::lightintense, meshes_, Face::normal, Vector::Normalize(), Vector::StoreNormalize(), and Face::v.
Referenced by setup().
std::vector<Mesh *> Model::meshes_ [protected] |
Definition at line 50 of file Model.h.
Referenced by addMesh(), centre(), getMeshes(), getNumberTriangles(), setupBones(), setupColor(), and ~Model().
std::vector<Bone *> Model::bones_ [protected] |
Definition at line 51 of file Model.h.
Referenced by addBone(), getBones(), setupBones(), and ~Model().
std::vector<BoneType *> Model::baseBoneTypes_ [protected] |
Definition at line 52 of file Model.h.
Referenced by getBaseBoneTypes(), setupBones(), and ~Model().
Vector Model::min_ [protected] |
Vector Model::max_ [protected] |
int Model::startFrame_ [protected] |
int Model::totalFrames_ [protected] |
1.5.3