Changeset 2382 for GTP/trunk/App/Demos/Vis/KdTreeDemo/OGRE/src
- Timestamp:
- 05/16/07 14:11:36 (18 years ago)
- Location:
- GTP/trunk/App/Demos/Vis/KdTreeDemo/OGRE/src
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
GTP/trunk/App/Demos/Vis/KdTreeDemo/OGRE/src/TestKdTree.cpp
r2361 r2382 209 209 mViewCells = cfDeath.getSetting("viewcells"); 210 210 211 212 211 213 tmp = cfDeath.getSetting("shadows"); 212 214 StringUtil::toLowerCase(tmp); … … 489 491 { 490 492 deaths = mSceneMgr->createEntity(cat(entName, i, j).c_str(),"robot.mesh"); 493 //deaths = mSceneMgr->createEntity(cat(entName, i, j).c_str(),"cube.mesh"); 491 494 if (mShadowsEnabled) 492 495 deaths->setCastShadows(true); … … 508 511 Math::RangeRandom(-planeThreeEights, planeThreeEights)); 509 512 deaths = mSceneMgr->createEntity(cat(entName,666,i),"robot.mesh"); 513 //deaths = mSceneMgr->createEntity(cat(entName,666,i),"cube.mesh"); 510 514 if (mShadowsEnabled) 511 515 deaths->setCastShadows(true); … … 528 532 Math::RangeRandom(-planeThreeEights, planeThreeEights)); 529 533 deaths = mSceneMgr->createEntity(cat(entName,666,i),"razor.mesh"); 534 //deaths = mSceneMgr->createEntity(cat(entName,666,i),"cube.mesh"); 530 535 if (mShadowsEnabled) 531 536 deaths->setCastShadows(true); … … 613 618 { 614 619 // Get the SceneManager 620 mOptions.mSceneManager=3; //changed cse 615 621 mSceneMgr = mRoot->createSceneManager( 616 622 KdTreeAppListener::SCENEMANAGERNAME[mOptions.mSceneManager], … … 619 625 if (mOptions.mSceneManager == KdTreeAppListener::SM_KDT || 620 626 mOptions.mSceneManager == KdTreeAppListener::SM_KTE || 621 mOptions.mSceneManager == KdTreeAppListener::SM_BVH) 627 mOptions.mSceneManager == KdTreeAppListener::SM_BVH || 628 mOptions.mSceneManager == KdTreeAppListener::SM_BIH ) 622 629 { 623 630 mSceneMgr->setOption("BuildMethod", &mOptions.mBuildMethod); 624 631 mSceneMgr->setOption("KdTreeMaxDepth", &mOptions.mMaxDepth); 625 632 mSceneMgr->setOption("KT", &mOptions.mKT); 633 mOptions.mKI=20; 626 634 mSceneMgr->setOption("KI", &mOptions.mKI); 627 635 mSceneMgr->setOption("RenderMethod", &mOptions.mRenderMethod); 628 636 mSceneMgr->setOption("EnhancedVisibility", &mOptions.mEnhancedVisibility); 637 bool show=true; 638 mSceneMgr->setOption("ShowBiHierarchy", &show); 639 mSceneMgr->setOption("ShowAllBoxes", &show); 640 629 641 } 630 642 // set algorithm when scene manager is OCM - numbering is different though … … 652 664 mCamera = mSceneMgr->createCamera("PlayerCam"); 653 665 mCamera->setNearClipDistance(1); 666 667 SceneNode *TempNode=mSceneMgr->getRootSceneNode();//->createChildSceneNode("PlayerCamNode", Vector3(0,0,0)); 668 printf("TempNode: %d\n",TempNode); 669 654 670 655 671 mCamNode = mSceneMgr->getRootSceneNode()->createChildSceneNode("PlayerCamNode", Vector3(0,0,0)); … … 901 917 { 902 918 SceneNode *node = root->createChildSceneNode("IVSceneNode" + index); 919 903 920 904 921 mIVReader->buildTree(mSceneMgr, node); -
GTP/trunk/App/Demos/Vis/KdTreeDemo/OGRE/src/TestKdTreeAppListener.cpp
r2359 r2382 19 19 const String KdTreeAppListener::BUILDMETHOD[] = { "RE", "PQ" }; 20 20 const String KdTreeAppListener::BUILDMETHODCAPTION[] = { "Recursive", "Priority Queue" }; 21 const String KdTreeAppListener::SCENEMANAGER[] = { "KDT", "KTE", "BVH", "OCM", "OCT", "TER", "GEN" };21 const String KdTreeAppListener::SCENEMANAGER[] = { "KDT", "KTE", "BVH","BIH", "OCM", "OCT", "TER", "GEN" }; 22 22 const String KdTreeAppListener::SCENEMANAGERNAME[] = 23 23 { … … 25 25 "KdTreeTerrainSceneManager", 26 26 "BvHierarchySceneManager", 27 "BiHierarchySceneManager", 27 28 "OcclusionCullingSceneManager", 28 29 "OctreeSceneManager", … … 113 114 mFreeMove(false), 114 115 mTopCamFollow(true), 115 mShowTree(SHOWTREE_ OFF),116 mShowTree(SHOWTREE_ALL), 116 117 // view cells 117 118 mViewCellsLoaded(false), … … 1239 1240 if (evt.timeSinceLastFrame == 0) 1240 1241 { 1241 mMoveScale = 1;1242 mMoveScale = 0.2; 1242 1243 mRotScale = 0.1; 1243 1244 } … … 1347 1348 { 1348 1349 togglePlayback(); 1350 saveLog(); 1349 1351 // exit app when in demo mode 1350 1352 if (mOptions.mDemoMode)
Note: See TracChangeset
for help on using the changeset viewer.