Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008 #ifndef __SP_TREEBUILDER_H__
00009 #define __SP_TREEBUILDER_H__
00010
00011
00012 #include "Base/spStandard.hpp"
00013 #include "Base/spTreeNode.hpp"
00014 #include "Base/spTreeNodeBSP.hpp"
00015 #include "Base/spTreeNodeQuad.hpp"
00016 #include "Base/spTreeNodeOct.hpp"
00017 #include "Base/spTreeNodeKD.hpp"
00018 #include "Base/spTreeNodeOBB.hpp"
00019 #include "Base/spTreeNodeImage.hpp"
00020 #include "Base/spMathTriangleCutter.hpp"
00021 #include "SceneGraph/spSceneMesh.hpp"
00022 #include "SceneGraph/Collision/spCollisionConfigTypes.hpp"
00023
00024
00025 namespace sp
00026 {
00027 namespace scene
00028 {
00029
00030
00032 enum EKDTreeBuildingConcepts
00033 {
00034 KDTREECONCEPT_CENTER,
00035 KDTREECONCEPT_AVERAGE,
00036 };
00037
00038
00045 namespace TreeBuilder
00046 {
00047
00057 SP_EXPORT KDTreeNode* buildKdTree(
00058 const std::list<Mesh*> &MeshList, u8 MaxTreeLevel = 12,
00059 const EKDTreeBuildingConcepts Concept = KDTREECONCEPT_CENTER, bool PreTransform = true
00060 );
00061
00063 SP_EXPORT KDTreeNode* buildKdTree(
00064 Mesh* Object, u8 MaxTreeLevel = 12, const EKDTreeBuildingConcepts Concept = KDTREECONCEPT_CENTER
00065 );
00066
00067 SP_EXPORT OcTreeNode* buildOcTree(Mesh* Object, u8 MaxTreeLevel = 4);
00068 SP_EXPORT QuadTreeNode* buildQuadTree(Mesh* Object, u8 MaxTreeLevel = 6);
00069 SP_EXPORT BSPTreeNode* buildBSPTree(Mesh* Object, u8 MaxTreeLevel = 12);
00070 SP_EXPORT OBBTreeNode* buildOBBTree(const std::list<dim::obbox3df> &BoxList);
00071
00072 }
00073
00074
00075 }
00076
00077 }
00078
00079
00080 #endif
00081
00082
00083
00084