Changeset 310 for trunk/VUT/GtpVisibilityPreprocessor/src/ViewCellBsp.cpp
- Timestamp:
- 10/05/05 18:36:16 (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/VUT/GtpVisibilityPreprocessor/src/ViewCellBsp.cpp
r309 r310 17 17 int BspTree::sMaxCandidates = 10; 18 18 int BspTree::sSplitPlaneStrategy = NEXT_POLYGON; 19 int BspTree::sConstructionMethod = VIEW_CELLS;19 int BspTree::sConstructionMethod = FROM_INPUT_VIEW_CELLS; 20 20 int BspTree::sTermMaxPolysForAxisAligned = 50; 21 21 … … 263 263 mStoreSplitPolys(false) 264 264 { 265 mypvs<BspNode *> testpvs; testpvs.Find(mRoot); 265 266 Randomize(); // initialise random generator for heuristics 266 267 } … … 1059 1060 void BspTree::ParseEnvironment() 1060 1061 { 1062 //-- parse bsp cell tree construction method 1063 char constructionMethodStr[60]; 1064 1065 environment->GetStringValue("BspTree.constructionMethod", constructionMethodStr); 1066 1067 sConstructionMethod = FROM_INPUT_VIEW_CELLS; 1068 1069 if (strcmp(constructionMethodStr, "fromViewCells") == 0) 1070 sConstructionMethod = FROM_INPUT_VIEW_CELLS; 1071 else if (strcmp(constructionMethodStr, "fromSceneGeometry") == 0) 1072 sConstructionMethod = FROM_SCENE_GEOMETRY; 1073 else if (strcmp(constructionMethodStr, "fromRays") == 0) 1074 sConstructionMethod = FROM_RAYS; 1075 else 1076 { 1077 cerr << "Wrong construction method " << constructionMethodStr << endl; 1078 exit(1); 1079 } 1080 1081 Debug << "Construction method: " << constructionMethodStr << endl; 1082 1061 1083 environment->GetIntValue("BspTree.Termination.maxDepth", sTermMaxDepth); 1062 1084 environment->GetIntValue("BspTree.Termination.maxPolygons", sTermMaxPolygons); … … 1092 1114 1093 1115 Debug << endl; 1094 1095 //-- parse BSP tree construction method1096 char constructionMethodStr[60];1097 1098 environment->GetStringValue("BspTree.constructionMethod", constructionMethodStr);1099 1100 sConstructionMethod = BspTree::VIEW_CELLS;1101 1102 if (strcmp(constructionMethodStr, "viewCells") == 0)1103 sConstructionMethod = BspTree::VIEW_CELLS;1104 else if (strcmp(constructionMethodStr, "sceneGeometry") == 0)1105 sConstructionMethod = BspTree::SCENE_GEOMETRY;1106 else if (strcmp(constructionMethodStr, "rays") == 0)1107 sConstructionMethod = BspTree::RAYS;1108 else1109 {1110 cerr << "Wrong bsp construction method " << constructionMethodStr << endl;1111 exit(1);1112 }1113 1114 Debug << "Construction method: " << constructionMethodStr << endl;1115 1116 } 1116 1117
Note: See TracChangeset
for help on using the changeset viewer.