Ignore:
Timestamp:
06/16/05 18:58:29 (19 years ago)
Author:
mattausch
Message:

fixed from camera visibility queries.
deletion of (previously) rendered queue items now before rendering the node (more intuitive)
improved octree implementation (tighter boxes)
added boxes for visibility queries

Location:
trunk/VUT/work/TestCullingTerrain
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/VUT/work/TestCullingTerrain/TerrainFrameListener.cpp

    r135 r137  
    196196                 // Get results, create a node/entity on the position 
    197197                 mCurrentObject = mTerrainContentGenerator->GenerateSceneObject( 
    198                          mouseRay.getOrigin(), Vector3::ZERO, "robot"); 
     198                         mouseRay.getOrigin()/*queryResult*/, Vector3::ZERO, "robot"); 
    199199                 
    200200         mLMouseDown = true;  
  • trunk/VUT/work/TestCullingTerrain/TestCullingTerrainApplication.cpp

    r135 r137  
    4040        *       because then the camera is displayed correctly in the visualization 
    4141        */ 
    42         mCamNode = mSceneMgr->getRootSceneNode()->createChildSceneNode( 
    43                 "CamNode1", Vector3(707, 5000, 528)); 
     42        mCamNode = mSceneMgr->getRootSceneNode()-> 
     43                createChildSceneNode("CamNode1", Vector3(707, 5000, 528)); 
    4444        //mCamera->setPosition(707, 5000, 528); 
    4545        mCamNode->setOrientation(Quaternion(-0.3486, 0.0122, 0.9365, 0.0329)); 
     
    9595        mSunLight->setCastShadows(true); 
    9696 
     97        // set light angle not too sharp, otherwise shadows textures will be broken 
    9798        Vector3 dir(0.5, 1, 0.5); 
    9899        dir.normalise(); 
     
    103104        mSunLight->setSpecularColour(1, 1, 1); 
    104105 
    105         // --Fog 
     106        // -- Fog 
    106107        // NB it's VERY important to set this before calling setWorldGeometry  
    107108        // because the vertex program picked will be different 
     
    135136        mSceneMgr->getRootSceneNode()->createChildSceneNode()->attachObject(pPlaneEnt); 
    136137        */ 
    137  
    138         if (mRoot->getRenderSystem()->getCapabilities()->hasCapability(RSC_HWRENDER_TO_TEXTURE)) 
    139     { 
    140                 // In D3D, use a 1024x1024 shadow texture 
    141                 mSceneMgr->setShadowTextureSettings(1024, 2); 
    142         } 
    143         else 
    144         { 
     138        mSceneMgr->setShadowTextureSettings(1024, 2); 
     139/*      if (mRoot->getRenderSystem()->getCapabilities()->hasCapability(RSC_HWRENDER_TO_TEXTURE)) 
     140    {   // In D3D, use a 1024x1024 shadow texture 
     141                mSceneMgr->setShadowTextureSettings(1024, 2);   }       else    { 
    145142                // Use 512x512 texture in GL since we can't go higher than the window res 
    146                 mSceneMgr->setShadowTextureSettings(512, 2); 
    147         } 
     143                mSceneMgr->setShadowTextureSettings(512, 2);} 
     144                */ 
     145 
    148146        //mSceneMgr->setShadowColour(ColourValue(0, 0, 0)); 
    149147        mSceneMgr->setShadowColour(ColourValue(0.5, 0.5, 0.5)); 
Note: See TracChangeset for help on using the changeset viewer.