00001 /*! \file 00002 \author victorien ferry & www.m4nkind.com 00003 \brief This file applies the GNU LESSER GENERAL PUBLIC LICENSE Version 2.1 , read file COPYING. 00004 */ 00005 #ifndef COM_M4NKIND_EquationSpline_X_H 00006 #define COM_M4NKIND_EquationSpline_X_H 00007 00008 #include "VirtualEquationSpline.h" 00009 #include "PackFloat.h" 00010 #include "PackList_TimeTrack.h" 00011 /*! 00012 \class EquationSpline_X 00013 \ingroup BaseObjectInherited_VedaLibMath BaseObjectInheritedDocGroup 00014 \brief Spline function for X 00015 */ 00016 class EquationSpline_X : public VirtualEquationSpline 00017 { 00018 /*================================================================== 00019 PUBLIC 00020 ==================================================================*/ 00021 public: 00022 /*! 00023 \brief Constructor. There should only be members initialisation there. 00024 */ 00025 EquationSpline_X(void); 00026 00027 /*! 00028 \brief Class Inheritance Descriptors. Also forces a destructor. See BASEOBJECT_DECLARE_... in .cpp 00029 */ 00030 BASEOBJECT_DEFINE_CLASS(EquationSpline_X); 00031 00032 /*! 00033 \brief static method passed to the list to create new elements. 00034 \return a new element. 00035 */ 00036 static PackList_TimeTrack::TimeTrackElement *NewSplineElementX(){ return new SplineElement(PackFloat::vd_X); }; 00037 00038 #ifdef _ENGINE_EDITABLE_ 00039 typedef enum { 00040 tm_VEquationSpline_Shift=tm_BaseObject_FirstInheritageToolMethod, 00041 tm_VEquationSpline_Scale, 00042 tm_VEquationSpline_Optimize, 00043 tm_VEquationSpline_ImportWaveVolume, 00044 tm_VEquationSpline_ImportWaveFreq, 00045 tm_VEquationSpline_FirstInheritageToolMethod, 00046 }; 00047 /*! 00048 \brief Tool Method main entry. In editable mode, the object can register a set of methods identified 00049 with an ID number by using RegisterToolMethod(), and throw the methods through a switch in ToolMethod(). 00050 Here, It is used to export wave sound format. 00051 \param _MethodIDToExecute the tool method ID, greater than 0. 00052 */ 00053 virtual void ExecuteToolMethod( unsigned int _MethodIDToExecute ) ; 00054 #endif 00055 #ifdef _ENGINE_EDITABLE_ 00056 /*! 00057 \brief 00058 */ 00059 void ToolMethod_Shift() ; 00060 #endif 00061 #ifdef _ENGINE_EDITABLE_ 00062 /*! 00063 \brief 00064 */ 00065 void ToolMethod_Scale() ; 00066 #endif 00067 #ifdef _ENGINE_EDITABLE_ 00068 /*! 00069 \brief 00070 */ 00071 void ToolMethod_Optimize() ; 00072 #endif 00073 #ifdef _ENGINE_EDITABLE_ 00074 /*! 00075 \brief 00076 */ 00077 void ToolMethod_ImportWaveVolume() ; 00078 #endif 00079 #ifdef _ENGINE_EDITABLE_ 00080 /*! 00081 \brief 00082 */ 00083 void ToolMethod_ImportWaveFreq() ; 00084 #endif 00085 /*================================================================== 00086 PROTECTED 00087 ==================================================================*/ 00088 protected: 00089 //! list of objects in the scenes. According to the type of class, it can be serialized (Scene3D) or created ( Scene3DText ) 00090 PackList_TimeTrack mSer_List; 00091 /*! 00092 \brief Return a list that manages SplineElement. 00093 \return the list 00094 */ 00095 virtual PackList_TimeTrack *GetList(){ return &mSer_List; }; 00096 00097 #ifdef _ENGINE_EDITABLE_ 00098 struct waveInfo 00099 { 00100 short nChannels; // number of channels (i.e. mono, stereo...) 00101 int nSamplesPerSec; // sample rate 00102 unsigned int dataStartOffset; 00103 unsigned int dataEndOffset; 00104 }; 00105 /*! 00106 \brief tool. 00107 */ 00108 static bool ToolMethod_Import_StartLoadWave(PackResource &_resource,struct waveInfo &_WaveInfo) ; 00109 #endif 00110 }; 00111 #endif
/\/\ 4 N k ! N D _______ _ __ ___ _____ ___ _ _ ____ ___________ __//___ /________ |/ / ___________\_______/ \ / _ _ \/ _ / _ / _/_/____/ _ __ / / / / / / / \ \/ / / \ \ / \\___/___/___/ ¯ _____/_____/ ______\___/_____/\________\\ \________/_ ___ __ l____\ /elD! http://www.m4nkind.com \____/