Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 8358 in orxonox.OLD for branches


Ignore:
Timestamp:
Jun 14, 2006, 2:41:35 AM (18 years ago)
Author:
patrick
Message:

bsp: bone informations get read

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_bone_frame.h

    r8357 r8358  
    1616{
    1717
     18typedef struct MD3BoneFrameData {
     19  sVec3D  mins;
     20  sVec3D  maxs;
     21  sVec3D  position;
     22  float   scale;
     23  char    creator[16];
     24};
     25
     26
    1827class MD3Tag;
    1928
     
    2736
    2837
    29   private:
    30     Vector         mins;              //!< lower extrema of the bounding box of this bone anumation frame
    31     Vector         maxs;              //!< upper extrema of the bounding box of this bone anumation frame
    32     Vector         position;          //!< coordinate origin within the bounding box
     38  public:
     39    Vector              mins;              //!< lower extrema of the bounding box of this bone anumation frame
     40    Vector              maxs;              //!< upper extrema of the bounding box of this bone anumation frame
     41    Vector              position;          //!< coordinate origin within the bounding box
    3342
    34     std::string    cratorName;        //!< the name of the creator
    35     float          scale;             //!< scale of the box
     43    std::string         cratorName;        //!< the name of the creator
     44    float               scale;             //!< scale of the box
    3645
    37     MD3Tag*        tags;              //!< arrays of tags size
     46    MD3Tag*             tags;              //!< arrays of tags size
    3847
    39 
     48    MD3BoneFrameData*   data;
    4049};
    4150
  • branches/bsp_model/src/lib/graphics/importer/md3/md3_data.cc

    r8357 r8358  
    222222  printf("fileSize: %i\n", this->header->fileSize);
    223223
    224 
    225224  return sizeof(MD3Header);
    226225}
     
    235234
    236235  for( int i = 0; i < this->header->boneFrameNum; i++)
     236  {
    237237    this->boneFrames[i] = new MD3BoneFrame(i);
    238238
     239    MD3BoneFrameData* md = new MD3BoneFrameData;
     240    fread(md, 1, sizeof(MD3BoneFrameData), pFile);
     241  }
     242
     243  return this->header->boneFrameNum * sizeof(MD3BoneFrameData);
     244}
     245
     246
     247/**
     248 * read the tags
     249 */
     250int MD3Data::readTags(FILE* pFile, int fileOffset)
     251{
    239252  return 0;
    240253}
     
    242255
    243256/**
    244  * read the tags
    245  */
    246 int MD3Data::readTags(FILE* pFile, int fileOffset)
     257 * read meshes
     258 */
     259int MD3Data::readMeshes(FILE* pFile, int fileOffset)
    247260{
    248261  return 0;
    249262}
    250263
    251 
    252 /**
    253  * read meshes
    254  */
    255 int MD3Data::readMeshes(FILE* pFile, int fileOffset)
    256 {
    257   return 0;
    258 }
    259 
    260 }
    261 
     264}
     265
Note: See TracChangeset for help on using the changeset viewer.