working on Mesh support
- loads only Milkshape ASCII - doesn't yet load textures or render with materials
This commit is contained in:
@@ -0,0 +1,55 @@
|
||||
#ifndef Model_H
|
||||
#define Model_H
|
||||
/*
|
||||
-----------------------------------------------------------------------------
|
||||
Class: Model
|
||||
|
||||
Desc: A 3D model.
|
||||
|
||||
Copyright (c) 2001-2002 by the person(s) listed below. All rights reserved.
|
||||
Chris Danford
|
||||
-----------------------------------------------------------------------------
|
||||
*/
|
||||
|
||||
#include "Actor.h"
|
||||
#include "RageTypes.h"
|
||||
|
||||
struct msModel;
|
||||
|
||||
typedef float matrix_t[3][4];
|
||||
typedef struct
|
||||
{
|
||||
matrix_t mRelative;
|
||||
matrix_t mAbsolute;
|
||||
matrix_t mRelativeFinal;
|
||||
matrix_t mFinal;
|
||||
} myBone_t;
|
||||
|
||||
|
||||
class Model : public Actor
|
||||
{
|
||||
public:
|
||||
Model ();
|
||||
virtual ~Model ();
|
||||
|
||||
public:
|
||||
void Clear ();
|
||||
bool Load(const char *szFilename);
|
||||
|
||||
virtual void Update( float fDelta );
|
||||
virtual void DrawPrimitives();
|
||||
|
||||
float CalcDistance () const;
|
||||
void SetupBones ();
|
||||
void AdvanceFrame (float dt);
|
||||
|
||||
private:
|
||||
msModel *m_pModel;
|
||||
RageVector3 m_vMins, m_vMaxs;
|
||||
myBone_t *m_pBones;
|
||||
float m_fCurrFrame;
|
||||
};
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user