Changeset 8566 in orxonox.OLD for branches/bsp_model/src
- Timestamp:
- Jun 17, 2006, 2:29:16 PM (18 years ago)
- Location:
- branches/bsp_model/src/lib/graphics/importer/md3
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/bsp_model/src/lib/graphics/importer/md3/md3_data.h
r8550 r8566 106 106 std::string loadFilename; //!< filename of the actual file from which data was loaded 107 107 108 int boneFrameNum; //!< number of anumation key fames in the models109 int tagNum; //!< number of tags110 int meshNum; //!< number of meshes111 112 int maxTextureNum; //!< maximum number of unique used in an md3 file113 int boneFrameStart; //!< starting position of bone frame data structures114 int tagStart; //!< starting position of tag-structures115 116 int meshStart; //!< starting position of mesh structures117 118 int fileSize; //!< file size119 120 108 MD3AnimationState animationState; //!< the animation state of this model 121 109 -
branches/bsp_model/src/lib/graphics/importer/md3/md3_model.cc
r8565 r8566 43 43 this->tmpBoneFrame = new MD3BoneFrame(); 44 44 45 this->tmpMesh = new sVec3D*[this->md3Data-> meshNum];46 for( int i = 0; i < this->md3Data-> meshNum; i++)45 this->tmpMesh = new sVec3D*[this->md3Data->header->meshNum]; 46 for( int i = 0; i < this->md3Data->header->meshNum; i++) 47 47 this->tmpMesh[i] = new sVec3D[this->md3Data->meshes[i]->header->vertexNum]; 48 48 49 this->tmpNormal = new MD3Normal*[this->md3Data-> meshNum];50 for( int i = 0; i < this->md3Data-> meshNum; i++)49 this->tmpNormal = new MD3Normal*[this->md3Data->header->meshNum]; 50 for( int i = 0; i < this->md3Data->header->meshNum; i++) 51 51 this->tmpNormal[i] = new MD3Normal[this->md3Data->meshes[i]->header->vertexNum]; 52 52 53 this->tmpMatrix = new float*[this->md3Data-> tagNum];54 for( int i = 0; i < this->md3Data-> tagNum; i++)53 this->tmpMatrix = new float*[this->md3Data->header->tagNum]; 54 for( int i = 0; i < this->md3Data->header->tagNum; i++) 55 55 this->tmpMatrix[i] = new float[16]; 56 56 } … … 92 92 93 93 //draw all meshes of current frame of this model 94 for( int i = 0; i < data-> meshNum; i++)94 for( int i = 0; i < data->header->meshNum; i++) 95 95 { 96 96 MD3Mesh* mesh = data->meshes[i]; … … 190 190 void MD3Model::draw() const 191 191 { 192 PRINTF(0)("draw\n");193 194 192 //draw current bone frame 195 193 this->draw(this->md3Data); … … 221 219 222 220 //draw all meshes of current frame of this model 223 for( int i = 0; i < data-> meshNum; i++)221 for( int i = 0; i < data->header->meshNum; i++) 224 222 { 225 223 MD3Mesh* mesh = data->meshes[i];
Note: See TracChangeset
for help on using the changeset viewer.