- Timestamp:
- 03/31/06 17:29:32 (19 years ago)
- Location:
- GTP/trunk/Lib/Illum/IBRBillboardCloudTrees/OGRE/include/LBBC
- Files:
-
- 16 edited
Legend:
- Unmodified
- Added
- Removed
-
GTP/trunk/Lib/Illum/IBRBillboardCloudTrees/OGRE/include/LBBC/LBBC.h
r700 r721 7 7 #include <LBBCLeafKdTreeClusterData.h> 8 8 #include <LBBCSampleConfigFile.h> 9 #include <LBBCBillboardViewMode.h> 10 #include <LBBCClusterViewMode.h> 9 11 10 12 #endif -
GTP/trunk/Lib/Illum/IBRBillboardCloudTrees/OGRE/include/LBBC/LBBCBillboardKMeansClusterData.h
r700 r721 1 #ifndef _LBBCBILLBOARDKM EANSCLUSTERDATA_H2 #define _LBBCBILLBOARDKM EANSCLUSTERDATA_H1 #ifndef _LBBCBILLBOARDKMeansCLUSTERDATA_H 2 #define _LBBCBILLBOARDKMeansCLUSTERDATA_H 3 3 4 4 #include <BBC.h> 5 #include <LBBCLeafKMeansClusterData.h> 6 #include <LBBCLeaf.h> 5 7 6 8 namespace LBBC { … … 10 12 BillboardKMeansClusterData(); 11 13 12 ~BillboardKMeansClusterData(); 14 virtual ~BillboardKMeansClusterData(); 15 16 virtual void readBillboardClusterData(TiXmlNode *parentNode); 17 18 virtual void writeBillboardClusterData(TiXmlNode *parentNode); 19 20 virtual void generateBillboardBoundingQuad(); 13 21 14 22 }; -
GTP/trunk/Lib/Illum/IBRBillboardCloudTrees/OGRE/include/LBBC/LBBCBillboardKdTreeClusterData.h
r700 r721 1 #ifndef _LBBCBILLBOARDK DTREECLUSTERDATA_H2 #define _LBBCBILLBOARDK DTREECLUSTERDATA_H1 #ifndef _LBBCBILLBOARDKdTreeCLUSTERDATA_H 2 #define _LBBCBILLBOARDKdTreeCLUSTERDATA_H 3 3 4 4 #include <BBC.h> 5 #include <LBBCLeafKdTreeClusterData.h>6 #include <LBBCLeaf.h>7 5 8 6 namespace LBBC { … … 12 10 BillboardKdTreeClusterData(); 13 11 14 ~BillboardKdTreeClusterData(); 15 16 virtual void readBillboardClusterData(TiXmlNode *parentNode); 17 18 virtual void writeBillboardClusterData(TiXmlNode *parentNode); 19 20 virtual void generateBillboardBoundingQuad(); 12 virtual ~BillboardKdTreeClusterData(); 21 13 22 14 }; -
GTP/trunk/Lib/Illum/IBRBillboardCloudTrees/OGRE/include/LBBC/LBBCKMeansClusterGenerator.h
r700 r721 1 #ifndef _LBBCKMEANSCLUSTERGENERATOR_H 2 #define _LBBCKMEANSCLUSTERGENERATOR_H 3 1 #ifndef _LBBCKMeansCLUSTERGENERATOR_H 2 #define _LBBCKMeansCLUSTERGENERATOR_H 4 3 5 4 #include <BBC.h> 5 #include <LBBCLeafKMeansClusterData.h> 6 #include <LBBCBillboardKMeansClusterData.h> 7 #include <LBBCLeaf.h> 8 #include <LBBCLeafDistribution.h> 6 9 7 10 namespace LBBC { 8 11 9 class _BBCExport KMeansClusterGenerator : public BBC::BillboardCloudGenerator { 12 class _BBCExport KMeansClusterGenerator: public BBC::BillboardCloudGenerator 13 { 10 14 public: 11 15 void generate(); … … 13 17 void init(); 14 18 19 void setAlpha(float value); 20 21 float getAlpha(); 22 23 void initializeBillboardCloud(); 24 25 BBC::BillboardPtr createBillboard(); 26 27 void initializeBillboardClusterData(BBC::BillboardPtr billboard); 28 29 void initializeRandomBillboard(BBC::BillboardPtr billboard); 30 31 void splitLeafDistribution(); 32 33 void assignLeafBillboard(Leaf *leaf, BBC::BillboardPtr billboard); 34 35 void recomputeBillboardCloud(); 36 37 void recomputeBillboard(BBC::BillboardPtr billboard); 38 39 void iterativeRecomputeBillboardCloud(); 40 41 unsigned int findBestBillboard(Leaf *leaf); 42 43 void generateBillboardCloudBounds(); 44 45 void setNumIterations(unsigned int value); 46 47 unsigned int getNumIterations(); 48 15 49 KMeansClusterGenerator(); 16 50 17 ~KMeansClusterGenerator();51 virtual ~KMeansClusterGenerator(); 18 52 19 53 protected: 20 54 21 class Cell 22 { 23 protected: 24 Cell *right; 25 Cell *left; 26 Ogre::Vector4 min; 27 Ogre::Vector4 max; 28 29 public: 30 Cell() 31 { 32 right = NULL; 33 left = NULL; 34 } 55 float mAlpha; 35 56 36 void setLeftChild(Cell *lChild) 37 { 38 left = lChild; 39 } 57 float mEpsilonYN; 40 58 41 void setRightChild(Cell *rChild) 42 { 43 right = rChild; 44 } 45 46 Cell* getRightChild() 47 { 48 return right; 49 } 50 51 Cell* getLeftChild() 52 { 53 return left; 54 } 55 56 Ogre::Vector4 getMin() 57 { 58 return min; 59 } 60 61 Ogre::Vector4 getMax() 62 { 63 return max; 64 } 65 66 void setMax(Ogre::Vector4 vmax) 67 { 68 max = vmax; 69 } 70 71 void setMin(Ogre::Vector4 vmin) 72 { 73 min = vmin; 74 } 75 }; 76 59 float mNumIterations; 77 60 }; 78 61 -
GTP/trunk/Lib/Illum/IBRBillboardCloudTrees/OGRE/include/LBBC/LBBCKMeansClusterSerializer.h
r700 r721 1 #ifndef _LBBCKM EANSCLUSTERSERIALIZER_H2 #define _LBBCKM EANSCLUSTERSERIALIZER_H1 #ifndef _LBBCKMeansCLUSTERSERIALIZER_H 2 #define _LBBCKMeansCLUSTERSERIALIZER_H 3 3 4 4 #include <BBC.h> 5 #include <LBBCBillboardKMeansClusterData.h> 6 7 #include <string> 5 8 6 9 namespace LBBC { … … 10 13 KMeansClusterSerializer(); 11 14 12 ~KMeansClusterSerializer();15 virtual ~KMeansClusterSerializer(); 13 16 14 17 virtual void writeBillboardCloud(TiXmlDocument *document); 15 18 16 19 }; -
GTP/trunk/Lib/Illum/IBRBillboardCloudTrees/OGRE/include/LBBC/LBBCKdTreeClusterGenerator.h
r700 r721 1 #ifndef _LBBCKDTREECLUSTERGENERATOR_H 2 #define _LBBCKDTREECLUSTERGENERATOR_H 1 #ifndef _LBBCKdTreeCLUSTERGENERATOR_H 2 #define _LBBCKdTreeCLUSTERGENERATOR_H 3 3 4 4 5 #include <BBC.h> 5 #include <LBBCLeafKdTreeClusterData.h>6 #include <LBBCBillboardKdTreeClusterData.h>7 #include <LBBCLeaf.h>8 #include <LBBCLeafDistribution.h>9 6 10 7 namespace LBBC { … … 16 13 void init(); 17 14 18 void setAlpha(float value);19 20 float getAlpha();21 22 void initializeBillboardCloud();23 24 BBC::Billboard* createBillboard();25 26 void initializeBillboardClusterData(BBC::Billboard *billboard);27 28 void initializeRandomBillboard(BBC::Billboard *billboard);29 30 void splitLeafDistribution();31 32 void assignLeafBillboard(Leaf *leaf, BBC::Billboard *billboard);33 34 void recomputeBillboardCloud();35 36 void recomputeBillboard(BBC::Billboard *billboard);37 38 void iterativeRecomputeBillboardCloud();39 40 unsigned int findBestBillboard(Leaf *leaf);41 42 void generateBillboardCloudBounds();43 44 void setNumIterations(unsigned int value);45 46 unsigned int getNumIterations();47 48 15 KdTreeClusterGenerator(); 49 16 50 ~KdTreeClusterGenerator();17 virtual ~KdTreeClusterGenerator(); 51 18 52 19 protected: 53 20 54 float mAlpha; 21 class Cell 22 { 23 protected: 24 Cell *right; 25 Cell *left; 26 Ogre::Vector4 min; 27 Ogre::Vector4 max; 28 29 public: 30 Cell() 31 { 32 right = NULL; 33 left = NULL; 34 } 55 35 56 float mEpsilonYN; 36 void setLeftChild(Cell *lChild) 37 { 38 left = lChild; 39 } 57 40 58 float mNumIterations; 41 void setRightChild(Cell *rChild) 42 { 43 right = rChild; 44 } 45 46 Cell* getRightChild() 47 { 48 return right; 49 } 50 51 Cell* getLeftChild() 52 { 53 return left; 54 } 55 56 Ogre::Vector4 getMin() 57 { 58 return min; 59 } 60 61 Ogre::Vector4 getMax() 62 { 63 return max; 64 } 65 66 void setMax(Ogre::Vector4 vmax) 67 { 68 max = vmax; 69 } 70 71 void setMin(Ogre::Vector4 vmin) 72 { 73 min = vmin; 74 } 75 }; 76 59 77 }; 60 78 -
GTP/trunk/Lib/Illum/IBRBillboardCloudTrees/OGRE/include/LBBC/LBBCKdTreeClusterSerializer.h
r700 r721 1 #ifndef _LBBCK DTREECLUSTERSERIALIZER_H2 #define _LBBCK DTREECLUSTERSERIALIZER_H1 #ifndef _LBBCKdTreeCLUSTERSERIALIZER_H 2 #define _LBBCKdTreeCLUSTERSERIALIZER_H 3 3 4 4 #include <BBC.h> 5 #include <LBBCBillboardKdTreeClusterData.h>6 7 #include <string>8 5 9 6 namespace LBBC { … … 13 10 KdTreeClusterSerializer(); 14 11 15 ~KdTreeClusterSerializer();12 virtual ~KdTreeClusterSerializer(); 16 13 17 virtualvoid writeBillboardCloud(TiXmlDocument *document);14 void writeBillboardCloud(TiXmlDocument *document); 18 15 19 16 }; -
GTP/trunk/Lib/Illum/IBRBillboardCloudTrees/OGRE/include/LBBC/LBBCLeaf.h
r700 r721 81 81 Leaf(); 82 82 83 ~Leaf();83 virtual ~Leaf(); 84 84 85 85 }; -
GTP/trunk/Lib/Illum/IBRBillboardCloudTrees/OGRE/include/LBBC/LBBCLeafDistribution.h
r700 r721 19 19 LeafDistribution(); 20 20 21 ~LeafDistribution();21 virtual ~LeafDistribution(); 22 22 23 23 void setMinD(float value); -
GTP/trunk/Lib/Illum/IBRBillboardCloudTrees/OGRE/include/LBBC/LBBCLeafDistributionGenerator.h
r700 r721 14 14 LeafDistributionGenerator(); 15 15 16 ~LeafDistributionGenerator();16 virtual ~LeafDistributionGenerator(); 17 17 18 18 void generateAverageLeafNormal(Leaf *leaf); -
GTP/trunk/Lib/Illum/IBRBillboardCloudTrees/OGRE/include/LBBC/LBBCLeafDistributionSerializer.h
r700 r721 13 13 LeafDistributionSerializer(); 14 14 15 ~LeafDistributionSerializer();15 virtual ~LeafDistributionSerializer(); 16 16 17 17 -
GTP/trunk/Lib/Illum/IBRBillboardCloudTrees/OGRE/include/LBBC/LBBCLeafKMeansClusterData.h
r700 r721 1 #ifndef _LBBCLEAFKM EANSCLUSTERDATA_H2 #define _LBBCLEAFKM EANSCLUSTERDATA_H1 #ifndef _LBBCLEAFKMeansCLUSTERDATA_H 2 #define _LBBCLEAFKMeansCLUSTERDATA_H 3 3 4 4 #include <BBCEntityClusterData.h> … … 10 10 LeafKMeansClusterData(); 11 11 12 ~LeafKMeansClusterData(); 12 virtual ~LeafKMeansClusterData(); 13 14 protected: 13 15 14 16 }; -
GTP/trunk/Lib/Illum/IBRBillboardCloudTrees/OGRE/include/LBBC/LBBCLeafKdTreeClusterData.h
r700 r721 1 #ifndef _LBBCLEAFK DTREECLUSTERDATA_H2 #define _LBBCLEAFK DTREECLUSTERDATA_H1 #ifndef _LBBCLEAFKdTreeCLUSTERDATA_H 2 #define _LBBCLEAFKdTreeCLUSTERDATA_H 3 3 4 4 #include <BBCEntityClusterData.h> … … 10 10 LeafKdTreeClusterData(); 11 11 12 ~LeafKdTreeClusterData(); 13 14 protected: 12 virtual ~LeafKdTreeClusterData(); 15 13 16 14 }; -
GTP/trunk/Lib/Illum/IBRBillboardCloudTrees/OGRE/include/LBBC/LBBCLeaves.h
r700 r721 11 11 Leaves(); 12 12 13 ~Leaves();13 virtual ~Leaves(); 14 14 15 15 protected: 16 16 bool mMeshLoaded; 17 17 18 Ogre::Mesh *mMesh;18 BBC::EntityPtr mEntity; 19 19 20 20 BBC::BillboardCloud *mBillboardCloud; 21 21 22 22 public: 23 Ogre::Mesh* getMesh();23 BBC::EntityPtr getEntity(); 24 24 25 void set Mesh(Ogre::Mesh *value);25 void setEntity(BBC::EntityPtr value); 26 26 27 27 void load(); -
GTP/trunk/Lib/Illum/IBRBillboardCloudTrees/OGRE/include/LBBC/LBBCManager.h
r709 r721 2 2 #define _LBBCMANAGER_H 3 3 4 #include <BBC.h>5 4 #include <LBBCPrerequisites.h> 6 5 #include <LBBCLeaves.h> … … 22 21 ~Manager(); 23 22 24 void runSample(Ogre::String sampleConfigFile); 23 void runSampleConfigFile(); 24 25 void loadSampleConfigFile(Ogre::String sampleConfigFile); 25 26 26 27 SampleConfigFile* getSampleConfigFile(); 28 29 void setSampleConfigFile(SampleConfigFile *sampleConfigFile); 27 30 28 31 void generateEntityDistribution(); … … 72 75 BBC::OgreMeshSerializer *mOgreMeshSerializer; 73 76 74 SampleConfigFile mSampleCf;77 SampleConfigFile *mSampleConfigFile; 75 78 76 Ogre::ConfigFile mCf; 79 Ogre::ConfigFile *mConfigFile; 80 77 81 }; 78 82 -
GTP/trunk/Lib/Illum/IBRBillboardCloudTrees/OGRE/include/LBBC/LBBCSampleConfigFile.h
r709 r721 10 10 SampleConfigFile(); 11 11 12 ~SampleConfigFile();12 virtual ~SampleConfigFile(); 13 13 14 14 bool getEntityDistributionMerged();
Note: See TracChangeset
for help on using the changeset viewer.