Ignore:
Timestamp:
04/06/06 20:48:19 (18 years ago)
Author:
igarcia
Message:
 
File:
1 edited

Legend:

Unmodified
Added
Removed
  • GTP/trunk/Lib/Illum/IBRBillboardCloudTrees/OGRE/src/IBRBillboardCloudTreeApplication.cpp

    r721 r731  
    1919        for (unsigned int i = 0; i < 1; i++) 
    2020        { 
     21                mSampleConfigFile = new LBBC::SampleConfigFile(); 
     22                mSampleConfigFile->load(mOpts.cfg); 
     23 
    2124                this->setup(false); 
    22                 mLBBCManager = new LBBC::Manager();      
    23                 LBBC::SampleConfigFile *sampleConfigFile = new LBBC::SampleConfigFile(); 
    24                 sampleConfigFile->load(mOpts.cfg); 
    25                 mLBBCManager->setSampleConfigFile(sampleConfigFile);     
     25                mLBBCManager = new LBBC::LBBCManager();  
     26                mLBBCManager->setSampleConfigFile(mSampleConfigFile);    
    2627                //mLBBCManager->loadSampleConfigFile(mOpts.cfg); 
    2728                mLBBCManager->runSampleConfigFile();     
     
    3334                this->setup(true); 
    3435                this->go();      
     36                for (unsigned int iFrameListenerMode = 0; iFrameListenerMode < mFrameListener->getNumFrameListenerModes(); iFrameListenerMode++) 
     37                { 
     38                        mFrameListener->getFrameListenerMode(iFrameListenerMode)->destroyScene(); 
     39                } 
    3540                mRoot->shutdown();       
    3641                mWindow->destroy();              
    3742                delete mRoot; 
     43                delete mSampleConfigFile; 
    3844        } 
     45 
    3946} 
    4047 
     
    108115         
    109116        mSceneMgr = mFrameListener->getEnabledFrameListenerMode()->getSceneManager();    
     117 
    110118        { 
    111                 LBBC::ClustersViewMode *anotherFrameListenerMode; 
    112                 anotherFrameListenerMode = new LBBC::ClustersViewMode(mWindow,mFrameListener->getNumFrameListenerModes()); 
     119                LBBC::ClusterViewMode *anotherFrameListenerMode; 
     120                anotherFrameListenerMode = new LBBC::ClusterViewMode(mWindow,mFrameListener->getNumFrameListenerModes()); 
    113121                anotherFrameListenerMode->chooseSceneManager(); 
    114122                anotherFrameListenerMode->createCamera(); 
     
    118126        } 
    119127 
     128        //{ 
     129        //      LBBC::BillboardViewMode *anotherFrameListenerMode; 
     130        //      anotherFrameListenerMode = new LBBC::BillboardViewMode(mWindow,mFrameListener->getNumFrameListenerModes()); 
     131        //      anotherFrameListenerMode->chooseSceneManager(); 
     132        //      anotherFrameListenerMode->createCamera(); 
     133        //      anotherFrameListenerMode->createViewports(); 
     134        //      anotherFrameListenerMode->createScene(); 
     135        //      mFrameListener->addFrameListenerMode(anotherFrameListenerMode); 
     136        //} 
     137 
    120138        { 
    121                 LBBC::BillboardViewMode *anotherFrameListenerMode; 
    122                 anotherFrameListenerMode = new LBBC::BillboardViewMode(mWindow,mFrameListener->getNumFrameListenerModes()); 
    123                 anotherFrameListenerMode->chooseSceneManager(); 
    124                 anotherFrameListenerMode->createCamera(); 
    125                 anotherFrameListenerMode->createViewports(); 
    126                 anotherFrameListenerMode->createScene(); 
    127                 mFrameListener->addFrameListenerMode(anotherFrameListenerMode); 
     139                LBBC::EntityTextureAtlasViewMode *textureAtlasFrameListenerMode; 
     140                textureAtlasFrameListenerMode = new LBBC::EntityTextureAtlasViewMode(mWindow,mFrameListener->getNumFrameListenerModes()); 
     141                textureAtlasFrameListenerMode->chooseSceneManager(); 
     142                textureAtlasFrameListenerMode->createCamera(); 
     143                textureAtlasFrameListenerMode->createViewports(); 
     144                textureAtlasFrameListenerMode->setTextureAtlasSize(mSampleConfigFile->getBillboardCloudDiffuseColorEntityTextureAtlasSize()); 
     145                textureAtlasFrameListenerMode->setTextureAtlasBitRange(mSampleConfigFile->getBillboardCloudDiffuseColorEntityTextureAtlasBitRange()); 
     146                textureAtlasFrameListenerMode->setTextureAtlasNumSamples(mSampleConfigFile->getBillboardCloudDiffuseColorEntityTextureAtlasNumSamples()); 
     147                textureAtlasFrameListenerMode->setTextureName(mSampleConfigFile->getBillboardCloudDiffuseColorEntityTexturePrefixName()); 
     148                textureAtlasFrameListenerMode->setTextureAtlasName(mSampleConfigFile->getBillboardCloudDiffuseColorEntityTextureAtlasPrefixName()); 
     149                textureAtlasFrameListenerMode->setTextureAtlasFolder(mSampleConfigFile->getBillboardCloudFolder()); 
     150 
     151                mFrameListener->addFrameListenerMode(textureAtlasFrameListenerMode); 
     152                textureAtlasFrameListenerMode->createScene(); 
    128153        } 
    129154 
    130         mFrameListener->setEnabledFrameListenerMode(1); 
    131155        mFrameListener->removeFrameListenerMode(0); 
     156        mFrameListener->setEnabledFrameListenerMode(0); 
    132157 
    133158    mRoot->addFrameListener(mFrameListener); 
Note: See TracChangeset for help on using the changeset viewer.