- Timestamp:
- 05/07/07 17:52:44 (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
GTP/trunk/App/Demos/Vis/HillyTerrain/OGRE/TestCullingTerrainApplication.cpp
r2305 r2352 432 432 // terrain creation 433 433 std::string terrain_cfg("terrainCulling.cfg"); 434 434 435 mSceneMgr->setWorldGeometry(terrain_cfg); 435 436 436 437 // was terrain loaded? 437 438 mSceneMgr->getOption("ShowTerrain", &msShowHillyTerrain); 439 msShowHillyTerrain=true; 440 438 441 439 442 // hack view point for terrain … … 471 474 { 472 475 // the objects are generated randomly distributed over the terrain 473 if (1) generateScene( 1500, 0); // create robots474 if (0) generateScene( 100, 1); // create ninjas476 if (1) generateScene(500, 0); // create robots 477 if (0) generateScene(300, 1); // create ninjas 475 478 if (0) generateScene(1000, 2); // create trees 476 479 } 480 int MaxDepth=30; 481 mSceneMgr->setOption("BiHierarchyMaxDepth", &MaxDepth); 482 int Mode=1; 483 mSceneMgr->setOption("EnhancedVisibility", &Mode); 484 mSceneMgr->setOption("RebuildBiHierarchy", NULL); 485 mSceneMgr->setOption("RebuildKdTree", NULL); 477 486 } 478 487 //----------------------------------------------------------------------- … … 564 573 this); 565 574 566 mTerrainFrameListener->setPriority(10);567 mTerrainFrameListener->setPriority(10);568 mRoot->addFrameListener(mTerrainFrameListener); 575 //mTerrainFrameListener->setPriority(10); 576 //mTerrainFrameListener->setPriority(10); 577 mRoot->addFrameListener(mTerrainFrameListener); 569 578 } 570 579 //----------------------------------------------------------------------- … … 583 592 #else 584 593 585 mSceneMgr = mRoot->createSceneManager("OcclusionCullingSceneManager");586 587 //mSceneMgr = mRoot->createSceneManager("TerrainSceneManager"); 594 //mSceneMgr = mRoot->createSceneManager("OcclusionCullingSceneManager"); 595 596 //mSceneMgr = mRoot->createSceneManager("TerrainSceneManager"); 588 597 //mSceneMgr = mRoot->createSceneManager("OctreeSceneManager"); 589 590 //mSceneMgr = mRoot->createSceneManager("KdTreeSceneManager"); 598 //mSceneMgr = mRoot->createSceneManager("BiHierarchySceneManager"); 599 600 mSceneMgr = mRoot->createSceneManager("BiTreeTerrainSceneManager"); 591 601 592 602 #endif
Note: See TracChangeset
for help on using the changeset viewer.