69 lines
No EOL
2.3 KiB
C++
69 lines
No EOL
2.3 KiB
C++
#pragma once
|
|
|
|
#include "DnRenderBase.h"
|
|
|
|
class MAActorRenderBase : public CDnRenderBase, virtual public CMultiElement {
|
|
public:
|
|
MAActorRenderBase();
|
|
virtual ~MAActorRenderBase();
|
|
|
|
|
|
protected:
|
|
EtAniObjectHandle m_hObject;
|
|
std::string m_szAniFileName;
|
|
LOCAL_TIME m_LocalTime;
|
|
LOCAL_TIME m_AniTime;
|
|
EtVector3 m_vAniDistance;
|
|
EtVector3 m_vAddAniDistance;
|
|
EtVector3 m_vScale;
|
|
int m_nAniIndex;
|
|
float m_fFrame;
|
|
float m_fPrevFrame;
|
|
|
|
int m_nBlendAniIndex;
|
|
float m_fBlendAniFrame;
|
|
float m_fBlendFrame;
|
|
float m_fBlendStartFrame;
|
|
float m_fBlendCurFrame;
|
|
|
|
float m_fFPS;
|
|
public:
|
|
virtual EtVector3 *GetAniDistance();
|
|
|
|
// MixedAnimation 에서 fBlendFrame 은 처음 시작할때 블렌딩 Frame 과 Mixed 가 끝난 후에 Default 에니로 돌아갈때의 Frame 을 넣어주는것음!!
|
|
void AddMixedAnimation( const char *szActionBoneName, const char *szMaintenanceBoneName, int nAniIndex, float fFrame, float fBlendFrame = 3.f, float fEndBlendFrame = 3.f );
|
|
void AddMixedAnimation( int nBoneIndex, int nMaintenanceBoneIndex, int nAniIndex, float fFrame, float fBlendFrame = 3.f, float fEndBlendFrame = 3.f );
|
|
const char *GetBoneName( int nBoneIndex );
|
|
|
|
EtAniObjectHandle GetObjectHandle() { return m_hObject; }
|
|
|
|
bool GetBoundingSphere( SSphere &Sphere );
|
|
bool GetBoundingBox( SAABox &Box );
|
|
bool GetOriginalBoundingBox( SAABox &Box );
|
|
|
|
void SetScale( EtVector3 &vScale ) { m_vScale = vScale; }
|
|
EtVector3 *GetScale() { return &m_vScale; }
|
|
|
|
virtual void AddAniDistance( EtVector3 &vVec );
|
|
virtual void CalcAniDistance( int nAniIndex, float fFrame, float fPrevFrame, EtVector3 &vDist );
|
|
|
|
// DnRenderBase
|
|
virtual void ChangeAnimation( int nAniIndex, float fFrame = 0.f, float fBlendFrame = 0.f );
|
|
virtual void PreProcess( LOCAL_TIME LocalTime, float fDelta );
|
|
virtual void Process( EtMatrix *pmatWorld, LOCAL_TIME LocalTime, float fDelta );
|
|
virtual int GetAniIndex( const char *szAniName );
|
|
virtual EtMatrix GetBoneMatrix( const char *szBoneName );
|
|
virtual int GetBoneIndex( const char *szBoneName );
|
|
|
|
virtual void SetFPS( float fValue );
|
|
virtual float GetFPS();
|
|
|
|
virtual void SetFrame( float fValue );
|
|
virtual void SetPrevFrame( float fValue );
|
|
|
|
|
|
virtual bool bIsSingleBody(){ return false; }
|
|
virtual bool bIsPartsBody(){ return false; }
|
|
virtual void LoadSkin( const char *szSkinName, const char *szAniName ){};
|
|
void ResetActorRenderBase();
|
|
}; |