#pragma once const unsigned int MAX_PATH_COUNT = 2048; class cPatternSceneNode; struct sPatternPos { unsigned long mX; unsigned long mY; unsigned long mRange; bool mRelax; unsigned long mWaitTime; cPatternSceneNode* mNode; sPatternPos() { mX = 0; mY = 0; mRange = 0; mRelax = 0; mWaitTime = 0; mNode = 0; } }; /// ÆÐÅÏ class cPattern { public: cPattern( unsigned long patternIdx ); ~cPattern(); void Clear(); void ClearSceneList(); /// ÀúÀå bool SavePattern( cFileSaver& saver ); /// ÆÐÅÏ Á¤º¸±â·Ï void SetPatternInfo( bool type ) { mType = type; } /// À§Ä¡Á¤º¸ Ãß°¡ void AddNode( cPatternSceneNode* node ); void InsertNode( cPatternSceneNode* baseNode, cPatternSceneNode* node ); void RemoveNode( cPatternSceneNode* node ); void SetVisible( bool visible ); void UpdateAllPathLine(); void RenderPattern(); private: void SetActiveLine( unsigned int count ); public: /// À妽º unsigned long mPatternIdx; /// ŸÀÔ bool mType; NiColor mColor; /// ±æÃ£±â Á¤º¸ NiPoint2 mPathArray[MAX_PATH_COUNT]; unsigned int mPathCount; /// °æ·Î NiMeshPtr mPathLine; NiMaterialPropertyPtr mMatProp; NiVertexColorPropertyPtr mVertColorProp; NiWireframePropertyPtr mWireProp; /// scene node Á¤º¸ typedef tPointerList cSceneNodeList; cSceneNodeList mSceneNodeList; };