00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011 #ifndef __BEZIERPATCH_H__
00012 #define __BEZIERPATCH_H__
00013
00014 #include "Bsp/BspDll.h"
00015 #include "Common/Types.h"
00016 #include "Render/RenderDefs.h"
00017
00018 class KLVertex2;
00019 class KMatrix;
00020
00021
00022 class BSP_API KBezierPatch
00023 {
00024 protected:
00025 KLVertex2* m_pVertices;
00026 u16 m_nVertices;
00027 u16* m_pIndices;
00028 u16 m_nIndices;
00029
00030 inline double GetBezierPoint( double s, double t, KMatrix& m );
00031
00032 public:
00033 KBezierPatch();
00034 ~KBezierPatch();
00035
00036 void GenerateVertices( KLVertex2* pVertices, KPt& PatchSize );
00037
00038 KRVERTEXTYPE GetVertexType() { return KRLVERTEX2; }
00039 KLVertex2* GetpVertices() { return m_pVertices; }
00040 u16 GetnVertices() { return m_nVertices; }
00041 u16* GetpIndices() { return m_pIndices; }
00042 u16 GetnIndices() { return m_nIndices; }
00043 };
00044
00045 #endif __BEZIERPATCH_H__