00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025 #ifndef _ACTION_H
00026 #define _ACTION_H
00027
00028 #include "Template.h"
00029
00030 class CSLActionFCurve;
00031 class CSLStaticValue;
00032 class CSLXSIShapeReference;
00033
00046 class XSIEXPORT CSLAction
00047 : public CSLTemplate
00048 {
00049 public:
00055 CSLAction(CSLScene* in_pScene, CSLModel *in_pModel, CdotXSITemplate* in_pTemplate);
00056
00059 virtual ~CSLAction();
00060
00062 enum EActionType
00063 {
00064 SI_AT_FCURVE,
00065 SI_AT_STATICVALUE,
00066 SI_AT_EXPRESSION,
00067 SI_AT_CLUSTERKEY,
00068 SI_AT_CONSTRAINT,
00069 SI_AT_COMPOUND,
00070 SI_AT_SHAPECOMPOUND,
00071 SI_AT_NONE,
00072 };
00073
00077 virtual SI_Error Synchronize();
00078
00082 CSLTemplate::ETemplateType Type(){ return CSLTemplate::XSI_ACTION; }
00083
00087 EActionType GetActionType();
00088
00092 SI_Void SetActionType( EActionType in_Type );
00093
00097 virtual SI_Float GetEndTime();
00098
00102 virtual SI_Void SetEndTime( SI_Float in_fTime );
00103
00107 virtual SI_Float GetStartTime();
00108
00112 virtual SI_Void SetStartTime( SI_Float in_fTime );
00113
00114
00115
00121 SI_Error RemoveAnimation( SI_Int in_nIndex );
00122
00128 SI_Error RemoveAnimation( CSLActionFCurve *io_pToRemove );
00129
00133 CSLActionFCurve** GetAnimationList();
00134
00138 SI_Int GetAnimationCount();
00139
00143 virtual CSLActionFCurve* AddAnimation();
00144
00149 virtual CSLActionFCurve* AddAnimation( EFCurveInterpolationType in_InterpolationType );
00150
00154 SI_Error ClearAnimations();
00155
00160 CSLActionFCurve* ConnectAnimation(CSLActionFCurve* in_pNewAnimation);
00161
00162
00163
00169 SI_Error RemoveStaticValue( SI_Int in_nIndex );
00170
00176 SI_Error RemoveStaticValue( CSLStaticValue *io_pToRemove );
00177
00181 CSLStaticValue** GetStaticValueList();
00182
00186 SI_Int GetStaticValueCount();
00187
00191 CSLStaticValue* AddStaticValue();
00192
00196 SI_Error ClearStaticValues();
00197
00202 CSLStaticValue* ConnectStaticValue(CSLStaticValue* in_pNewStaticValue);
00203
00204 CSLFloatProxy* GetStartTimeProxy() {return &m_StartTime;};
00205 CSLFloatProxy* GetEndTimeProxy() {return &m_EndTime;};
00206 CSLEnumProxy<EActionType, SI_AT_NONE>* GetActionTypeProxy() { return &m_ActionType;};
00207
00211 CSLXSIShapeReference* AddXSIShapeReference();
00212
00216 CSLXSIShapeReference* GetXSIShapeReference();
00217
00221 SI_Error ClearXSIShapeReference();
00222
00227 CSLXSIShapeReference* ConnectXSIShapeReference(CSLXSIShapeReference* in_pNewXSIShape);
00228
00229 private:
00230 CSLFloatProxy m_StartTime;
00231 CSLFloatProxy m_EndTime;
00232 CSLEnumProxy<EActionType, SI_AT_NONE> m_ActionType;
00233 CSIBCArray<CSLActionFCurve*> m_Animations;
00234 CSIBCArray<CSLStaticValue*> m_StaticValues;
00235 CSLXSIShapeReference *m_pXSIShapeReference;
00236 };
00237 #endif