Changeset 2188 for GTP/trunk/App/Demos/Illum/Ogre/src/PRMDemo/include
- Timestamp:
- 03/05/07 18:04:13 (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
GTP/trunk/App/Demos/Illum/Ogre/src/PRMDemo/include/PRMDemo.h
r2186 r2188 94 94 //mSceneMgr = mRoot->createSceneManager("OcclusionCullingSceneManager"); 95 95 } 96 97 /* 98 void createScene(void) /// SHADOWACCUM 99 { 100 //std::string occlusion_cfg("OcclusionCulling.cfg"); 101 //mSceneMgr->setWorldGeometry(occlusion_cfg); 102 //createPostproc(); 103 104 OgreIlluminationManager::getSingleton().setMainCamera(mCamera); 105 OgreIlluminationManager::getSingleton().setMainViewport(mWindow->getViewport(0)); 106 OgreIlluminationManager::getSingleton().setShadowMapMaterialName("GTP/Basic/CameraDepth"); 107 OgreIlluminationManager::getSingleton().setFocusingSM(false); 108 OgreIlluminationManager::getSingleton().setShadowMapSize(512); 109 OgreIlluminationManager::getSingleton().setBlurShadowMap(false); 110 OgreIlluminationManager::getSingleton().setUseLISPSM(false); 111 OgreIlluminationManager::getSingleton().setAreaLigtRadius(3); 112 113 Root::getSingleton()._setCurrentSceneManager(mSceneMgr); 114 mCamera->setPosition(0,0,0); 115 //mCamera->setPosition(0,100,0); 116 //mCamera->lookAt(0,-1,0); 117 mCamera->setFOVy(Radian(Degree(80))); 118 mCamera->setNearClipDistance(0.01); 119 mCamera->setFarClipDistance(1000); 120 // Set ambient light 121 mSceneMgr->setAmbientLight(ColourValue(0,0, 0)); 122 //mSceneMgr->setSkyBox(true, "Examples/EveningSkyBox", 500); 123 124 SceneNode* rootNode = mSceneMgr->getRootSceneNode(); 125 126 127 SceneSerializer s(mSceneMgr); 128 DataStreamPtr inputStream; 129 //inputStream = ResourceGroupManager::getSingleton().openResource("level.txt"); //towers2.level 130 //s.parseScript(inputStream, ResourceGroupManager::DEFAULT_RESOURCE_GROUP_NAME); 131 132 Entity* pillar = mSceneMgr->createEntity("pillar", "pillarShape.mesh"); 133 SceneNode* pillarNode = rootNode->createChildSceneNode("pillarnode"); 134 pillarNode->attachObject(pillar); 135 136 137 createPlane("p","GTP/Basic/ShadowReciever/ShadowAccum",Vector3(0,-1,0),Vector2(20,20),Vector2(1,1)); 138 139 Light* mainLight = mSceneMgr->createLight("MainLight"); 140 mainLight->setType(Light::LT_SPOTLIGHT); 141 mainLight->setCastShadows(true); 142 mainLight->setDiffuseColour(ColourValue::White); 143 mainLight->setSpecularColour(ColourValue::White); 144 mainLightNode = rootNode->createChildSceneNode(); 145 146 mainLightNode->setPosition(5,5,5); 147 mainLight->setPosition(5,5,5); 148 mainLight->setPowerScale(5); 149 mainLight->setDirection(-1,-1, -1); 150 mainLight->setSpotlightOuterAngle(Radian(Degree(90))); 151 mainLight->setAttenuation(20, 1, 0, 0); 152 mainLightNode->attachObject(mainLight); 153 154 BillboardSet* bbs = mSceneMgr->createBillboardSet("bb", 1); 155 bbs->setDefaultDimensions(5,5); 156 bbs->createBillboard(Vector3::ZERO, ColourValue::White); 157 bbs->setMaterialName("Flare"); 158 mainLightNode->attachObject(bbs); 159 160 OgreIlluminationManager::getSingleton().initTechniques(); 161 }*/ 96 162 /* 97 void createScene(void) 163 void createScene(void) ///TOWERS 98 164 { 99 165 //std::string occlusion_cfg("OcclusionCulling.cfg"); … … 148 214 }*/ 149 215 150 void createScene(void) 216 void createScene(void) ///PATHMAP Hangar 151 217 { 152 218 //std::string occlusion_cfg("OcclusionCulling.cfg");
Note: See TracChangeset
for help on using the changeset viewer.