- Timestamp:
- 03/31/06 17:29:32 (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
GTP/trunk/Lib/Illum/IBRBillboardCloudTrees/OGRE/include/IMG/IMGCluster.h
r700 r721 2 2 #define _IMGCLUSTER_H 3 3 4 #include "IMGPrerequisites.h" 5 #include "IMGBBox.h" 6 #include "IMGBox2d.h" 7 #include "IMGPlane3.h" 4 #include <IMGPrerequisites.h> 5 #include <IMGBBox.h> 6 #include <IMGBox2d.h> 7 #include <IMGPlane3.h> 8 #include <IMGCluster2d.h> 8 9 9 namespace IMG { class Cluster2d; } 10 namespace IMG 11 { 10 12 11 namespace IMG { 12 13 class Cluster { 13 class Cluster 14 { 14 15 public: 15 16 Cluster(); … … 19 20 Cluster(const Cluster & p); 20 21 21 // Gametools -- Isma 17/08/2005 22 //void Insert (Triangle *t); 23 // Gametools -- Isma 17/08/2005 24 //* return the patchs that the point is in 25 //int CalculaPatch (Vector3 &point); 26 inline void SetNormal(Ogre::Vector3* n) { normal = *n; }; 22 void SetNormal(Ogre::Vector3* n); 27 23 28 inline Ogre::Vector3* GetNormal() { return &normal; };24 Ogre::Vector3* GetNormal(); 29 25 30 inline BBox* GetBound() { return bound; };26 BBox* GetBound(); 31 27 32 inline Box2d* GetBspNodeBound() { return bspnodebound; };28 Box2d* GetBspNodeBound(); 33 29 34 inline void SetBspNodeBound(Box2d* box) { 35 bspnodebound = box; 36 }; 30 void SetBspNodeBound(Box2d* box); 37 31 38 32 void Print(); … … 41 35 int AxisProjected(); 42 36 43 in line int GetId() const { return id; };37 int GetId() const; 44 38 45 inline void SetId(int id_) { id = id;};39 void SetId(int id_); 46 40 47 //Vector3 * GetVector3s() const{ return Vector3s;} 48 //Vector3 * GetVector3s(); 49 //Vector3 * GetVector3s() { return Vector3s_triangle_text; } 50 inline std::vector<Ogre::Vector3>* GetVector3sVector() { return &Vector3s_vector; }; 41 std::vector<Ogre::Vector3>* GetVector3sVector(); 51 42 52 inline Ogre::Vector3* GetVector3sTex() const { return Vector3s_triangle_text;};43 Ogre::Vector3* GetVector3sTex() const; 53 44 54 // Gametools -- Isma 17/08/200555 //bool CreatePatches(bool dinamic = false);56 // Gametools -- Isma 17/08/200557 //Listid *GetPatchList() { return &patchlistid;}58 //Listid *GetTriangleList(){ return &trianglelistid; }59 // Gametools -- Isma 17/08/200560 //int GetIdPatch (unsigned int i)61 //{62 // if (i > patchlistid.GetSize()) return -1;63 //64 // return patchlistid.Get(i);65 //}66 // Gametools -- Isma 17/08/200567 //int GetIdTriangle (unsigned int i)68 //{69 // if (i > trianglelistid.GetSize()) return -1;70 //71 // return trianglelistid.Get(i);72 //}73 45 void Finish(); 74 46 75 inline void SetPlane(Ogre::Vector3* normal, Ogre::Vector3 * point) { 76 plane.normal = *normal; 77 plane.normal = -plane.normal; 78 plane.d = -normal->dotProduct (*point); 79 //plane.d = normal->dotProduct (*point); 80 }; 47 void SetPlane(Ogre::Vector3* normal, Ogre::Vector3 * point); 81 48 82 inline Plane3 * GetPlane() { return &plane; };49 Plane3 * GetPlane(); 83 50 84 51 //* Return the increment in U (lumel increment in x). For patchs calculation … … 91 58 Ogre::Vector3 GetOrigin(); 92 59 93 //94 // void CreateVector3s()95 // {96 //97 // //Vector3s = new Vector3[4];98 // //Vector3s_triangle_text = new Vector3[4];99 // }100 //101 60 bool PointIn(Ogre::Vector3 & point); 102 61 103 Ogre::Real *pointeru[4]; //coordentate u for obscurancemap 104 Ogre::Real *pointerv[4]; //coordentate v for obscurancemap 105 Ogre::Vector2 *uv; //Vector3 coordenates for the original texture 62 Ogre::Real *pointeru[4]; 63 64 Ogre::Real *pointerv[4]; 65 66 Ogre::Vector2 *uv; 106 67 107 68 private: 108 BBox *bound;69 BBox bound; 109 70 110 Box2d *bspnodebound;71 Box2d bspnodebound; 111 72 112 73 static unsigned int ID_CLUSTER; … … 117 78 118 79 std::vector<Ogre::Vector3> Vector3s_vector; 80 119 81 Ogre::Vector3 *Vector3s; 82 120 83 Ogre::Vector3 *Vector3s_triangle_text; 121 84 … … 130 93 Plane3 plane; 131 94 132 // Gametools -- Isma 17/08/2005133 //Listid patchlistid;134 //Listid trianglelistid;135 int CalcPatch(Ogre::Vector3 & point);136 137 138 95 public: 139 ~Cluster();96 virtual ~Cluster(); 140 97 141 98 };
Note: See TracChangeset
for help on using the changeset viewer.