Ignore:
Timestamp:
08/22/07 14:27:41 (17 years ago)
Author:
mattausch
Message:
 
File:
1 edited

Legend:

Unmodified
Added
Removed
  • GTP/trunk/Lib/Vis/Preprocessing/src/ViewCellsManager.cpp

    r2544 r2547  
    10211021        if (!Debug.is_open()) Debug.open("debug.log"); 
    10221022 
    1023         // give just an empty container as parameter: 
    1024         // this loading function is used in the engine, thus it 
    1025         // does not need to load the entities the preprocessor works on 
    1026         ObjectContainer preprocessorObjects; 
    1027  
    1028         return LoadViewCells(filename,  
    1029                                                  pvsObjects, 
    1030                                                  preprocessorObjects, 
    1031                                                  finalizeViewCells, 
    1032                                                  bconverter); 
    1033 } 
    1034  
     1023 
     1024        if (strstr(filename.c_str(), ".bn")) 
     1025        { 
     1026                Debug << "binary view cells format detected" << endl; 
     1027 
     1028                return LoadViewCellsBinary(filename,  
     1029                                               pvsObjects, 
     1030                                                                   finalizeViewCells, 
     1031                                                                   bconverter); 
     1032        } 
     1033        else 
     1034        { 
     1035                Debug << "xml view cells format detected" << endl; 
     1036 
     1037                // give just an empty container as parameter: 
     1038                // this loading function is used in the engine, thus it 
     1039                // does not need to load the entities the preprocessor works on 
     1040                ObjectContainer preprocessorObjects; 
     1041 
     1042                return LoadViewCells(filename,  
     1043                                         pvsObjects, 
     1044                                                         preprocessorObjects, 
     1045                                                         finalizeViewCells, 
     1046                                                         bconverter); 
     1047        } 
     1048} 
    10351049 
    10361050void ViewCellsManager::LoadIndexedBoundingBoxesBinary(IN_STREAM &stream, IndexedBoundingBoxContainer &iboxes) 
     
    71107124 
    71117125 
    7112  
    7113 ViewCellsManager *LoadViewCellsBinary(const string &filename,  
    7114                                                                           ObjectContainer &pvsObjects, 
    7115                                                                           bool finalizeViewCells, 
    7116                                                                           BoundingBoxConverter *bconverter)                                                                                               
    7117 { 
    7118         if (!Debug.is_open()) Debug.open("debug.log"); 
    7119  
     7126ViewCellsManager *ViewCellsManager::LoadViewCellsBinary(const string &filename,  
     7127                                                                                                                ObjectContainer &pvsObjects, 
     7128                                                                                                                bool finalizeViewCells, 
     7129                                                                                                                BoundingBoxConverter *bconverter)                                                                                                 
     7130{ 
    71207131        IN_STREAM stream(filename.c_str()); 
    71217132 
     
    71427153        } 
    71437154 
    7144         // sort objects by id 
    7145         //sort(pvsObjects.begin(), pvsObjects.end(), ilt); 
    7146  
    71477155 
    71487156        ObjectContainer pvsLookup; 
     
    71887196 
    71897197        Debug << "loading the view space partition tree" << endl; 
    7190         VspTree *vspTree = new VspTree(); 
    7191  
    7192         vspTree->mBoundingBox = viewSpaceBox; 
     7198        VspTree *vspTree = new VspTree(viewSpaceBox); 
    71937199 
    71947200        if (!vspTree->ImportBinary(stream)) 
Note: See TracChangeset for help on using the changeset viewer.