Ignore:
Timestamp:
01/19/08 05:28:24 (16 years ago)
Author:
mattausch
Message:

did some stuff for the visualization

Location:
GTP/trunk/Lib/Vis/Preprocessing/src
Files:
19 edited

Legend:

Unmodified
Added
Removed
  • GTP/trunk/Lib/Vis/Preprocessing/src/Containers.h

    r2609 r2615  
    55#include <queue> 
    66#include <map> 
     7#include "common.h" 
    78 
    89using std::vector; 
     
    1415class HierarchyNode; 
    1516class SceneGraphNode; 
     17class SceneGraphLeaf; 
    1618class Intersectable; 
    1719class Polygon3; 
     
    7375 
    7476/// a container for dynamic objects 
     77 
     78#if USE_TRANSFORMED_MESH_INSTANCE_HACK 
    7579typedef std::vector<TransformedMeshInstance *> DynamicObjectsContainer; 
    76  
     80#else 
     81typedef vector<SceneGraphLeaf *> DynamicObjectsContainer; 
     82#endif 
    7783 
    7884} 
  • GTP/trunk/Lib/Vis/Preprocessing/src/GlRenderer.cpp

    r2614 r2615  
    471471 
    472472 
     473void GlRenderer::_RenderDynamicObject(SceneGraphLeaf *leaf) 
     474{ 
     475        // apply world transform before rendering 
     476        Matrix4x4 m; 
     477        leaf->GetTransform(m); 
     478 
     479        glPushMatrix(); 
     480        glMultMatrixf((float *)m.x); 
     481 
     482        glBegin(GL_TRIANGLES); 
     483 
     484        ObjectContainer::const_iterator oi = leaf->mGeometry.begin(); 
     485        for (; oi != leaf->mGeometry.end(); oi++)  
     486        { 
     487                TriangleIntersectable *object = (TriangleIntersectable *)*oi; 
     488                Triangle3 *t = &(object->GetItem()); 
     489 
     490                Vector3 normal = t->GetNormal(); 
     491                glNormal3f(normal.x, normal.y, normal.z); 
     492 
     493                glVertex3f(t->mVertices[0].x, t->mVertices[0].y, t->mVertices[0].z); 
     494                glVertex3f(t->mVertices[1].x, t->mVertices[1].y, t->mVertices[1].z); 
     495                glVertex3f(t->mVertices[2].x, t->mVertices[2].y, t->mVertices[2].z); 
     496 
     497        } 
     498 
     499        glEnd(); 
     500 
     501        glPopMatrix(); 
     502} 
     503 
     504 
     505 
    473506void GlRenderer::_RenderSceneTriangles() 
    474507{ 
     
    499532{ 
    500533        Intersectable::NewMail(); 
    501  
     534#if DYNAMIC_OBJECTS_HACK 
    502535        Preprocessor *p = mViewCellsManager->GetPreprocessor(); 
    503536        // handle dynamic objects 
     
    506539        for (dit = p->mDynamicObjects.begin(); dit != dit_end; ++ dit) 
    507540        { 
    508                 RenderIntersectable(*dit); 
    509         } 
    510  
     541#if USE_TRANSFORMED_MESH_INSTANCE_HACK 
     542        RenderIntersectable(*dit); 
     543#else 
     544                _RenderDynamicObject(*dit); 
     545#endif 
     546        } 
     547#endif 
    511548#if 1 
    512549        _RenderSceneTrianglesWithDrawArrays(); 
  • GTP/trunk/Lib/Vis/Preprocessing/src/GlRenderer.h

    r2600 r2615  
    161161  RenderViewPoint(); 
    162162 
     163  void _RenderDynamicObject(SceneGraphLeaf *leaf); 
     164 
    163165  virtual void 
    164166  SetupProjection(const int w, const int h, const float angle = 70.0f); 
  • GTP/trunk/Lib/Vis/Preprocessing/src/GvsPreprocessor.cpp

    r2601 r2615  
    4848        Environment::GetSingleton()->GetBoolValue("Preprocessor.evaluatePixelError", mEvaluatePixelError); 
    4949 
     50        Environment::GetSingleton()->GetBoolValue("ViewCells.useKdPvs", mUseKdPvs); 
     51 
     52 
    5053        char gvsStatsLog[100]; 
    5154        Environment::GetSingleton()->GetStringValue("GvsPreprocessor.stats", gvsStatsLog); 
     
    183186                        obj->mCounter = 1; 
    184187                        mTrianglePvs.push_back(obj); 
    185  
    186                         /*mViewCellsManager->ComputeSampleContribution(ray,  
    187                                                                                                          true,  
    188                                                                                                          mCurrentViewCell, 
    189                                                                                                          true);*/ 
     188                 
     189                        if (mUseKdPvs) 
     190                        { 
     191                                KdNode *node = mKdTree->GetPvsNode(ray.mTermination); 
     192 
     193                                if (!node->Mailed()) 
     194                                { 
     195                                        node->Mail(); 
     196                                        mKdPvs.push_back(mKdTree->GetOrCreateKdIntersectable(node)); 
     197                                }                        
     198                        } 
    190199                         
    191200                        result = true; 
     
    863872        for (lit = leaves.begin(); lit != leaves.end(); ++ lit) 
    864873        { 
    865                 KdLeaf *leaf = *lit; 
     874        KdLeaf *leaf = *lit; 
     875                 
     876                if (mUseKdPvs) 
     877                        mKdPvs.push_back(mKdTree->GetOrCreateKdIntersectable(leaf)); 
     878 
    866879                ObjectContainer::const_iterator oit, oit_end = leaf->mObjects.end(); 
    867880 
     
    892905                (*oit)->mCounter = 0; 
    893906        } 
    894         int dummy = 0; 
     907         
     908         
    895909        while (NextViewCell())// && (dummy < 3)) 
    896910        { 
     
    898912                //if (mProcessedViewCells < 53) continue; 
    899913         
     914                if (mUseKdPvs) 
     915                { 
     916                        KdNode::NewMail(); 
     917                        mKdPvs.clear(); 
     918                } 
     919 
    900920                long startTime = GetTime(); 
    901921                cout << "\n***********************\n"  
     
    910930                mGvsStats.mTotalTrianglePvs += mGvsStats.mTrianglePvs; 
    911931 
    912                 ObjectContainer objectPvs; 
    913  
    914                 // exchange triangle pvs with objects 
    915                 //UpdatePvs(mCurrentViewCell); 
    916         GetObjectPvs(objectPvs); 
    917  
    918                 // add pvs 
    919                 ObjectContainer::const_iterator it, it_end = objectPvs.end(); 
    920  
    921                 for (it = objectPvs.begin(); it != it_end; ++ it) 
    922                 { 
    923                         mCurrentViewCell->GetPvs().AddSampleDirty(*it, 1.0f); 
    924                 } 
    925  
    926                 cout << "triangle pvs of " << (int)mTrianglePvs.size()  
    927                          << " was converted to object pvs of " << (int)objectPvs.size() << endl; 
    928                  
     932                if (!mUseKdPvs) 
     933                { 
     934                        ObjectContainer objectPvs; 
     935 
     936                        // optain object pvs 
     937                        GetObjectPvs(objectPvs); 
     938 
     939                        // add pvs 
     940                        ObjectContainer::const_iterator it, it_end = objectPvs.end(); 
     941 
     942                        for (it = objectPvs.begin(); it != it_end; ++ it) 
     943                        { 
     944                                mCurrentViewCell->GetPvs().AddSampleDirty(*it, 1.0f); 
     945                        } 
     946 
     947                        cout << "triangle pvs of " << (int)mTrianglePvs.size()  
     948                                << " was converted to object pvs of " << (int)objectPvs.size() << endl; 
     949 
     950                        mGvsStats.mPerViewCellPvs = (int)objectPvs.size(); 
     951                } 
     952                else 
     953                { 
     954                        // add pvs 
     955                        ObjectContainer::const_iterator it, it_end = mKdPvs.end(); 
     956 
     957                        for (it = mKdPvs.begin(); it != it_end; ++ it) 
     958                        { 
     959                                mCurrentViewCell->GetPvs().AddSampleDirty(*it, 1.0f); 
     960                        } 
     961 
     962                        mGvsStats.mPerViewCellPvs = mKdPvs.size(); 
     963                } 
    929964 
    930965                //////// 
     
    932967                 
    933968                mGvsStats.mViewCells = mProcessedViewCells;//mPass; 
    934                 //mGvsStats.mPerViewCellPvs = mCurrentViewCell->GetPvs().GetSize(); 
    935                 mGvsStats.mPerViewCellPvs = (int)objectPvs.size(); 
     969                 
    936970 
    937971                mGvsStats.mTotalPvs += mGvsStats.mPerViewCellPvs; 
     
    950984 
    951985        mTrianglePvs.clear(); 
    952  
     986#if 0 
    953987                if (GVS_DEBUG) 
    954988                { 
     
    957991                        CLEAR_CONTAINER(mVssRays); 
    958992                } 
    959  
    960                 // is this really necessary? 
    961                 //ClearRayQueue(); 
    962993                cout << "finished" << endl; 
     994 
    963995                if (mEvaluatePixelError || mExportVisibility) 
    964996                { 
    965997                        StorePvs(objectPvs); 
    966998                } 
     999#endif 
    9671000        } 
    9681001} 
     
    10391072 
    10401073        BvhLeaf::NewMail(); 
     1074        //KdNode::NewMail(); 
    10411075 
    10421076        ObjectContainer::const_iterator oit, oit_end = mTrianglePvs.end(); 
     
    10531087                if (!bv || bv->Mailed()) 
    10541088                        continue; 
    1055                  
     1089 
    10561090                bv->Mail(); 
    1057  
    10581091                objectPvs.push_back(bv); 
    10591092        } 
  • GTP/trunk/Lib/Vis/Preprocessing/src/GvsPreprocessor.h

    r2176 r2615  
    6767        float mTotalTime; 
    6868 
     69        ObjectContainer mKdPvs; 
     70 
    6971        float RaysPerSec() const { if (!mTotalTime) return 0; return (float)mTotalSamples / mTotalTime * 1e-6f; } 
    7072 
     
    223225        ////////////////////// 
    224226 
    225         //int mSamplesPerPass; 
    226         //int mTotalSamples; 
     227        bool mUseKdPvs; 
    227228        int mInitialSamples; 
    228229 
     
    236237         
    237238 
     239        ObjectContainer mKdPvs; 
    238240 
    239241        /////////// 
  • GTP/trunk/Lib/Vis/Preprocessing/src/Intersectable.h

    r2575 r2615  
    3939 
    4040        enum {MESH_INSTANCE,  
    41                 TRANSFORMED_MESH_INSTANCE,  
    42                 SPHERE,  
    43                 VIEW_CELL,  
    44                 OGRE_MESH_INSTANCE, 
    45                 KD_INTERSECTABLE, 
    46                 BVH_INTERSECTABLE, 
    47                 TRIANGLE_INTERSECTABLE, 
    48                 DUMMY_INTERSECTABLE, 
    49                 ENGINE_INTERSECTABLE, 
    50                 CONTAINER_INTERSECTABLE 
     41                  TRANSFORMED_MESH_INSTANCE,  
     42                  SPHERE,  
     43                  VIEW_CELL,  
     44                  OGRE_MESH_INSTANCE, 
     45                  KD_INTERSECTABLE, 
     46                  BVH_INTERSECTABLE, 
     47                  TRIANGLE_INTERSECTABLE, 
     48                  DUMMY_INTERSECTABLE, 
     49                  ENGINE_INTERSECTABLE, 
     50                  CONTAINER_INTERSECTABLE, 
     51                  SCENEGRAPHLEAF_INTERSECTABLE 
    5152        }; 
    5253 
  • GTP/trunk/Lib/Vis/Preprocessing/src/IntersectableWrapper.cpp

    r2604 r2615  
    225225} 
    226226 
    227 } 
     227 
     228SceneGraphLeafIntersectable::SceneGraphLeafIntersectable(SceneGraphLeaf *item, const AxisAlignedBox3 &box): 
     229  IntersectableWrapper<SceneGraphLeaf *>(item), mBox(box) 
     230{ 
     231} 
     232 
     233} 
  • GTP/trunk/Lib/Vis/Preprocessing/src/IntersectableWrapper.h

    r2604 r2615  
    267267}; 
    268268 
     269 
     270class SceneGraphLeafIntersectable: public IntersectableWrapper<SceneGraphLeaf *> 
     271{ 
     272public: 
     273        SceneGraphLeafIntersectable(SceneGraphLeaf *item, const AxisAlignedBox3 &box); 
     274     
     275        int ComputeNumTriangles() { return 0;} 
     276         
     277        int Type() const 
     278        { 
     279                return Intersectable::SCENEGRAPHLEAF_INTERSECTABLE; 
     280        } 
     281 
     282    AxisAlignedBox3 GetBox() const  
     283        { 
     284                return mBox; 
     285        } 
     286 
     287        /// the bounding box of this intersectable 
     288        AxisAlignedBox3 mBox; 
     289 
     290protected: 
     291 
     292//      int mNumTriangles; 
     293}; 
     294 
     295 
    269296} 
    270297 
  • GTP/trunk/Lib/Vis/Preprocessing/src/KdTree.cpp

    r2606 r2615  
    13721372bool KdTree::ImportBinTree(const string &filename, ObjectContainer &objects) 
    13731373{ 
    1374   // export binary version of mesh 
    1375   queue<TraversalData> tStack; 
    1376   IN_STREAM stream(filename.c_str(), IN_BIN_MODE); 
    1377    
    1378   if (!stream.is_open()) return false; 
    1379    
    1380   // sort objects by their id 
    1381   //    if (!is_sorted(objects.begin(), objects.end(), ilt)) 
    1382   sort(objects.begin(), objects.end(), ilt); 
    1383    
    1384   mBox.Initialize(); 
    1385   ObjectContainer::const_iterator oit, oit_end = objects.end(); 
    1386    
    1387   /////////////////////////// 
    1388   //-- compute bounding box of object space 
    1389    
    1390   for (oit = objects.begin(); oit != oit_end; ++ oit) 
    1391   { 
    1392     const AxisAlignedBox3 box = (*oit)->GetBox(); 
    1393     mBox.Include(box); 
    1394   } 
    1395    
    1396   // hack: we make a new root 
    1397   DEL_PTR(mRoot); 
    1398    
    1399   mRoot = ImportNextNode(stream, NULL, objects); 
    1400    
    1401   tStack.push(TraversalData(mRoot, mBox, 0)); 
    1402   mStat.Reset(); 
    1403   mStat.nodes = 1; 
    1404    
    1405   while(!tStack.empty()) 
    1406   { 
    1407     TraversalData tData = tStack.front(); 
    1408     tStack.pop(); 
    1409      
    1410     KdNode *node = tData.mNode; 
    1411      
    1412     if (!node->IsLeaf()) 
    1413     { 
    1414       mStat.nodes += 2; 
    1415        
    1416       //Debug << "i" ; 
    1417       KdInterior *interior = static_cast<KdInterior *>(node); 
    1418       interior->mBox = tData.mBox; 
    1419        
    1420       KdNode *front = ImportNextNode(stream, interior, objects); 
    1421       KdNode *back = ImportNextNode(stream, interior, objects); 
    1422        
    1423       interior->SetupChildLinks(back, front); 
    1424        
    1425       ++ mStat.splits[interior->mAxis]; 
    1426        
    1427       // compute new bounding box 
    1428       AxisAlignedBox3 frontBox, backBox; 
    1429        
    1430       tData.mBox.Split(interior->mAxis,  
    1431                        interior->mPosition,  
    1432                        frontBox,  
    1433                        backBox); 
    1434        
    1435       tStack.push(TraversalData(front, frontBox, tData.mDepth + 1));                     
    1436       tStack.push(TraversalData(back, backBox, tData.mDepth + 1)); 
    1437     } 
    1438     else 
    1439     { 
    1440       EvaluateLeafStats(tData); 
    1441       //cout << "l"; 
    1442     } 
    1443   } 
    1444  
    1445   float area = GetBox().SurfaceArea()*mKdPvsArea; 
    1446    
    1447   SetPvsTerminationNodes(area); 
    1448    
    1449   Debug << mStat << endl; 
    1450    
    1451   return true; 
     1374        // export binary version of mesh 
     1375        queue<TraversalData> tStack; 
     1376        IN_STREAM stream(filename.c_str(), IN_BIN_MODE); 
     1377 
     1378        if (!stream.is_open()) return false; 
     1379 
     1380        // sort objects by their id 
     1381        //      if (!is_sorted(objects.begin(), objects.end(), ilt)) 
     1382        sort(objects.begin(), objects.end(), ilt); 
     1383 
     1384        mBox.Initialize(); 
     1385        ObjectContainer::const_iterator oit, oit_end = objects.end(); 
     1386 
     1387        /////////////////////////// 
     1388        //-- compute bounding box of object space 
     1389 
     1390        for (oit = objects.begin(); oit != oit_end; ++ oit) 
     1391        { 
     1392                const AxisAlignedBox3 box = (*oit)->GetBox(); 
     1393                mBox.Include(box); 
     1394        } 
     1395 
     1396        // hack: we make a new root 
     1397        DEL_PTR(mRoot); 
     1398 
     1399        mRoot = ImportNextNode(stream, NULL, objects); 
     1400 
     1401        tStack.push(TraversalData(mRoot, mBox, 0)); 
     1402        mStat.Reset(); 
     1403        mStat.nodes = 1; 
     1404 
     1405        while(!tStack.empty()) 
     1406        { 
     1407                TraversalData tData = tStack.front(); 
     1408                tStack.pop(); 
     1409 
     1410                KdNode *node = tData.mNode; 
     1411 
     1412                if (!node->IsLeaf()) 
     1413                { 
     1414                        mStat.nodes += 2; 
     1415 
     1416                        //Debug << "i" ; 
     1417                        KdInterior *interior = static_cast<KdInterior *>(node); 
     1418                        interior->mBox = tData.mBox; 
     1419 
     1420                        KdNode *front = ImportNextNode(stream, interior, objects); 
     1421                        KdNode *back = ImportNextNode(stream, interior, objects); 
     1422 
     1423                        interior->SetupChildLinks(back, front); 
     1424 
     1425                        ++ mStat.splits[interior->mAxis]; 
     1426 
     1427                        // compute new bounding box 
     1428                        AxisAlignedBox3 frontBox, backBox; 
     1429 
     1430                        tData.mBox.Split(interior->mAxis,  
     1431                                interior->mPosition,  
     1432                                frontBox,  
     1433                                backBox); 
     1434 
     1435                        tStack.push(TraversalData(front, frontBox, tData.mDepth + 1));                   
     1436                        tStack.push(TraversalData(back, backBox, tData.mDepth + 1)); 
     1437                } 
     1438                else 
     1439                { 
     1440                        EvaluateLeafStats(tData); 
     1441                        //cout << "l"; 
     1442                } 
     1443        } 
     1444 
     1445        float area = GetBox().SurfaceArea()*mKdPvsArea; 
     1446 
     1447        SetPvsTerminationNodes(area); 
     1448 
     1449        Debug << mStat << endl; 
     1450 
     1451        return true; 
    14521452} 
    14531453 
     
    14561456KdTree::GetOrCreateKdIntersectable(KdNode *node) 
    14571457{ 
    1458   if (node == NULL) 
    1459     return NULL; 
     1458        if (node == NULL) 
     1459                return NULL; 
    14601460 
    14611461        if (node->mIntersectable == NULL)  
     
    14651465                KdIntersectable *kdObj = new KdIntersectable(node, GetBox(node)); 
    14661466                node->mIntersectable = kdObj; 
    1467                  
     1467 
    14681468                mKdIntersectables.push_back(kdObj); 
    14691469                kdObj->SetId(id); 
    14701470#ifdef USE_BIT_PVS 
    1471     // hack: for kd pvs the kd intersecables are the pvs objects 
    1472     ObjectPvsIterator::sObjects.push_back(kdObj); 
     1471                // hack: for kd pvs the kd intersecables are the pvs objects 
     1472                ObjectPvsIterator::sObjects.push_back(kdObj); 
    14731473#endif 
    1474   } 
    1475  
    1476   return node->mIntersectable; 
     1474        } 
     1475 
     1476        return node->mIntersectable; 
    14771477} 
    14781478 
     
    15191519} 
    15201520 
     1521 
     1522/*KdNode * 
     1523KdTree::GetPvsNode(const Triangle3 &tri) const 
     1524{ 
     1525  KdNode *node = mRoot; 
     1526   
     1527  while (node->mPvsTermination == 0 )  
     1528  { 
     1529          KdInterior *inter = (KdInterior *)node; 
     1530          if (point[inter->mAxis] < inter->mPosition) 
     1531                  node = inter->mBack; 
     1532          else 
     1533                  node = inter->mFront; 
     1534  } 
     1535 
     1536  return node; 
     1537}*/ 
     1538 
     1539 
     1540 
    15211541KdNode * 
    15221542KdTree::GetPvsNode(const Vector3 &point) const 
     
    15611581   
    15621582  while (!tStack.empty()) 
    1563     { 
    1564       KdNode *node = tStack.top(); 
    1565       tStack.pop(); 
    1566        
    1567       if (node->IsLeaf()) 
    1568         { 
    1569           leaves.push_back(static_cast<KdLeaf *>(node)); 
    1570         } 
    1571       else // interior 
    1572         { 
    1573           KdInterior *interior = static_cast<KdInterior *>(node); 
    1574            
    1575           if (box.Max(interior->mAxis) >= interior->mPosition) 
    1576             { 
    1577               tStack.push(interior->mFront); 
    1578             } 
    1579            
    1580           if (box.Min(interior->mAxis) < interior->mPosition) 
    1581             { 
    1582               tStack.push(interior->mBack); 
    1583             } 
    1584         } 
    1585     } 
    1586 } 
    1587  
    1588  
    1589  
    1590 } 
     1583  { 
     1584          KdNode *node = tStack.top(); 
     1585          tStack.pop(); 
     1586 
     1587          if (node->IsLeaf()) 
     1588          { 
     1589                  leaves.push_back(static_cast<KdLeaf *>(node)); 
     1590          } 
     1591          else // interior 
     1592          { 
     1593                  KdInterior *interior = static_cast<KdInterior *>(node); 
     1594 
     1595                  if (box.Max(interior->mAxis) >= interior->mPosition) 
     1596                  { 
     1597                          tStack.push(interior->mFront); 
     1598                  } 
     1599 
     1600                  if (box.Min(interior->mAxis) < interior->mPosition) 
     1601                  { 
     1602                          tStack.push(interior->mBack); 
     1603                  } 
     1604          } 
     1605  } 
     1606} 
     1607 
     1608 
     1609 
     1610} 
  • GTP/trunk/Lib/Vis/Preprocessing/src/Preprocessor.cpp

    r2614 r2615  
    12091209 
    12101210#if DYNAMIC_OBJECTS_HACK 
    1211  
    12121211                static Ray hRay; 
    12131212                VssRayContainer::iterator vit, vit_end = vssRays.end(); 
     
    12161215                { 
    12171216                        VssRay *vssRay = *vit; 
     1217 
     1218                        DynamicObjectsContainer::const_iterator tit, tit_end = mDynamicObjects.end(); 
     1219                        bool foundIntersect = false; 
     1220 
     1221#if USE_TRANSFORMED_MESH_INSTANCE_HACK 
    12181222                        hRay.Init(*vssRay); 
    1219  
    1220                         DynamicObjectsContainer::const_iterator tit, tit_end = mDynamicObjects.end(); 
    1221  
    1222                         bool foundIntersect = false; 
    12231223 
    12241224                        for (tit = mDynamicObjects.begin(); tit != tit_end; ++ tit) 
     
    12271227 
    12281228                                float maxT, minT; 
    1229          
    1230                                 // test with bounding box 
     1229                                        // test with bounding box 
    12311230                                if (tmi->GetBox().GetMinMaxT(hRay, &minT, &maxT)) 
    12321231                                { 
     
    12391238                        } 
    12401239 
    1241                         //if (foundIntersect)   cout << "x: " << Intersectable::GetTypeName(hRay.intersections[0].mObject); 
    1242  
    12431240                        if (foundIntersect) 
    12441241                        { 
     
    12491246 
    12501247                        hRay.intersections.clear(); 
     1248#else 
     1249 
     1250                        //////////// 
     1251                        // TODO Vlastimil 
     1252                         
     1253                        for (tit = mDynamicObjects.begin(); tit != tit_end; ++ tit)      
     1254                        { 
     1255                                // remove vss ray termination triangle with container object 
     1256                                if (foundIntersect) 
     1257                                { 
     1258                                        vssRay->mTerminationObject = (*tit)->GetIntersectable(); 
     1259                                } 
     1260                        } 
     1261 
     1262         
     1263#endif 
     1264 
     1265 
    12511266                } 
    12521267#endif 
     
    16401655                inStream.read(reinterpret_cast<char *>(&mesh->mVertices[i + 2]), sizeof(Vector3)); 
    16411656 
    1642                 /*mesh->mVertices[i].x += 20; 
    1643                 mesh->mVertices[i + 1].x += 20; 
    1644                 mesh->mVertices[i + 2].x += 20; 
    1645  
    1646                 mesh->mVertices[i].z -= 10; 
    1647                 mesh->mVertices[i + 1].z -= 10; 
    1648                 mesh->mVertices[i + 2].z -= 10; 
    1649 */ 
     1657                // hack: objects initially very small 
    16501658                mesh->mVertices[i] *= 100; 
    16511659                mesh->mVertices[i + 1] *= 100; 
     
    16711679{ 
    16721680        const bool dynamic = true; 
     1681#if DYNAMIC_OBJECTS_HACK 
     1682#if USE_TRANSFORMED_MESH_INSTANCE_HACK 
    16731683 
    16741684        Mesh *mesh = LoadBinaryObjIntoMesh(filename); 
     
    16821692 
    16831693                mSceneGraph->GetRoot()->mChildren.push_back(leaf); 
    1684                 //mDynamicObjects.push_back(leaf); 
     1694 
    16851695                mDynamicObjects.push_back(tmi); 
    1686  
    16871696                return true; 
    16881697        } 
    1689  
    1690  
     1698#else 
     1699 
     1700        SceneGraphLeaf *leaf = new SceneGraphLeaf(dynamic); 
     1701 
     1702        if (LoadBinaryObj(filename, leaf, NULL)) 
     1703        { 
     1704                mDynamicObjects.push_back(leaf); 
     1705                mSceneGraph->GetRoot()->mChildren.push_back(leaf); 
     1706                return true 
     1707        } 
     1708 
     1709#endif 
     1710#endif 
    16911711        return false; 
    16921712} 
  • GTP/trunk/Lib/Vis/Preprocessing/src/Preprocessor.h

    r2609 r2615  
    219219        /// the view cells manager 
    220220        ViewCellsManager *mViewCellsManager; 
    221  
    222         //SceneGraphNodeContainer mDynamicObjects; 
     221#if DYNAMIC_OBJECTS_HACK 
    223222        DynamicObjectsContainer mDynamicObjects; 
    224  
     223#endif 
    225224        /// greedy optimized hierarchy for both objects and view cells 
    226225        VspOspTree *mVspOspTree; 
  • GTP/trunk/Lib/Vis/Preprocessing/src/QtInterface/QtGlRenderer.cpp

    r2614 r2615  
    8888                                                                           KdTree *tree): 
    8989  QGLPixelBuffer(QSize(w, h)), 
    90   //QGLWidget(NULL, w, h), 
    9190  GlRendererBuffer(sceneGraph, viewcells, tree) 
    9291{ 
     
    380379        glNormalPointer(GL_FLOAT, 0, (char *)arrayPtr + offset * sizeof(Vector3)); 
    381380        glDrawElements(GL_TRIANGLES, mIndexBufferSize, GL_UNSIGNED_INT, mIndices); 
    382  
     381#if DYNAMIC_OBJECTS_HACK 
    383382        // handle dynamic objects 
    384383        DynamicObjectsContainer::const_iterator dit, dit_end = mDynamicObjects.end(); 
    385384 
     385 
    386386        for (dit = mDynamicObjects.begin(); dit != dit_end; ++ dit) 
    387387        { 
     388#if USE_TRANSFORMED_MESH_INSTANCE_HACK 
    388389                //cerr << "here45\n****"<<endl; 
    389390                RenderIntersectable(*dit); 
    390         } 
     391#else 
     392                RenderDynamicObject(*dit); 
     393#endif 
     394        } 
     395#endif 
    391396} 
    392397 
     
    400405 
    401406        mPvsSize = mPvsCache.mPvs.GetSize(); 
    402  
     407#if DYNAMIC_OBJECTS_HACK 
    403408        mDynamicObjects.clear(); 
    404  
     409#endif 
    405410        ObjectPvsIterator it = mPvsCache.mPvs.GetIterator(); 
    406411 
     
    416421                        } 
    417422                        break; 
     423#if DYNAMIC_OBJECTS_HACK 
     424#if USE_TRANSFORMED_MESH_INSTANCE_HACK 
     425 
    418426                case Intersectable::TRANSFORMED_MESH_INSTANCE: 
    419427                        mDynamicObjects.push_back(static_cast<TransformedMeshInstance *>(obj)); 
    420428                        break; 
     429 
     430#else 
     431                case Intersectable::SCENEGRAPHLEAF_INTERSECTABLE: 
     432                        mDynamicObjects.push_back(static_cast<SceneGraphLeafIntersectable *>(obj)->GetItem()); 
     433                        break; 
     434#endif 
     435#endif 
    421436                default: 
    422437                        cerr << "PreparePvs: type " << Intersectable::GetTypeName(obj) << " not handled yet" << endl; 
     
    513528                                //mPvsCache.mPvs = pvs; 
    514529                                //mMutex.unlock(); 
     530                                cout << "pvs size: " << mPvsCache.mPvs.GetSize() << endl; 
    515531                        } 
    516532                        else 
     
    667683                mViewPoint.x += (x-mousePoint.x)*MOVE_SENSITIVITY / 2.0; 
    668684        }  
     685#if DYNAMIC_OBJECTS_HACK 
    669686        else if (e->modifiers() & Qt::AltModifier) 
    670687        { 
     
    673690                        Matrix4x4 tm; 
    674691                        TransformedMeshInstance *tmi; 
     692#if USE_TRANSFORMED_MESH_INSTANCE_HACK 
    675693 
    676694                        switch (mTrafoType) 
     
    703721 
    704722                        tmi->ApplyWorldTransform(tm); 
     723#endif 
    705724                        updateGL(); 
    706725                } 
    707726        } 
     727#endif 
    708728        else 
    709729        { 
     
    10011021        connect(mControlWidget, SIGNAL(SetScale(bool)), this, SLOT(SetScale(bool))); 
    10021022         
    1003         // setting the size here 
    1004         resize(800, 600); 
     1023        setWindowTitle("PVS Visualization"); 
     1024 
     1025        // setting the main window size here 
     1026        //resize(800, 600); 
     1027        //resize(640, 480); 
     1028        //resize(512, 384); 
     1029        //resize(512, 320); 
     1030        resize(640, 400); 
     1031         
    10051032        mControlWidget->show(); 
    10061033} 
     
    13091336        while (pit.HasMoreEntries())     
    13101337        { 
     1338                KdIntersectable *kdObj = static_cast<KdIntersectable *>(pit.Next()); 
     1339 
    13111340                if (mShowDistanceWeightedPvs) 
    13121341                { 
    1313                         KdIntersectable *kdObj = static_cast<KdIntersectable *>(pit.Next()); 
    13141342                        const AxisAlignedBox3 box = kdObj->GetBox(); 
    13151343 
     
    13191347                else if (mShowDistanceWeightedTriangles) 
    13201348                { 
    1321                         KdIntersectable *kdObj = static_cast<KdIntersectable *>(pit.Next()); 
    13221349                        const AxisAlignedBox3 box = kdObj->GetBox(); 
    13231350 
     
    13271354                else //if (mShowWeightedTriangles) 
    13281355                { 
    1329                         KdIntersectable *kdObj = static_cast<KdIntersectable *>(pit.Next()); 
    13301356                        renderCost += kdObj->ComputeNumTriangles(); 
    13311357                } 
     
    14361462 
    14371463        ComputeMaxValues(viewcells, maxPvs, maxPiercingRays, maxRelativeRays, maxRcCost); 
    1438  
     1464        // matt: temp hack 
     1465        //maxRcCost = 200.0f; 
     1466        //cout << "maxRcCost: " << maxRcCost << endl; 
    14391467        int i; 
    14401468 
     
    14881516        else // using specialised colors 
    14891517        { 
    1490          
    1491  
    14921518                if (!mShowComparison) 
    14931519                        AssignImportanceByRelativeValue(viewcells, maxPvs, maxPiercingRays, maxRelativeRays, maxRcCost); 
     
    15571583                        importance = rcCost / maxRcCost; 
    15581584                } 
    1559  
     1585if (importance > 1.0f) importance = 1.0f; 
    15601586                // c = RgbColor(importance, 1.0f - importance, 0.0f); 
    15611587                c = RainbowColorMapping(importance); 
     
    16581684        connect(rb5, SIGNAL(toggled(bool)), SIGNAL(SetShowWeightedCost(bool))); 
    16591685 
    1660         QGroupBox *groupBox = new QGroupBox("Visualization options"); 
     1686        QGroupBox *groupBox = new QGroupBox("PVS Visualization"); 
    16611687 
    16621688        QVBoxLayout *vbox2 = new QVBoxLayout; 
     
    17711797 
    17721798         
    1773         QGroupBox *groupBox = new QGroupBox("Ray visualization options"); 
     1799        QGroupBox *groupBox = new QGroupBox("Ray visualization"); 
    17741800        QVBoxLayout *vbox2 = new QVBoxLayout; 
    17751801     
     
    18161842        QVBoxLayout *vl = new QVBoxLayout; 
    18171843        setLayout(vl); 
    1818  
    1819         QWidget *vbox = new QGroupBox("ViewCells", this); 
    1820         layout()->addWidget(vbox); 
    1821  
    1822         vl = new QVBoxLayout; 
    1823         vbox->setLayout(vl); 
     1844         
     1845        //QWidget *vbox; 
     1846 
     1847        //vbox = new QGroupBox("Render Controls", this); 
     1848        //layout()->addWidget(vbox); 
     1849        //vl = new QVBoxLayout; 
     1850        //vbox->setLayout(vl); 
    18241851 
    18251852        QLabel *label; 
     
    18301857 
    18311858        label = new QLabel("Granularity"); 
    1832         vbox->layout()->addWidget(label); 
     1859        //vbox->layout()->addWidget(label); 
     1860        vl->addWidget(label); 
    18331861 
    18341862        slider = new QSlider(Qt::Horizontal, vbox); 
     
    18441872 
    18451873        label = new QLabel("Transfer function"); 
    1846         vbox->layout()->addWidget(label); 
     1874        vl->addWidget(label); 
    18471875 
    18481876        slider = new QSlider(Qt::Horizontal, vbox); 
     
    18591887 
    18601888        button = new QPushButton("Update all PVSs", vbox); 
    1861         vbox->layout()->addWidget(button); 
     1889        vl->addWidget(button); 
    18621890        connect(button, SIGNAL(clicked()), SLOT(UpdateAllPvs())); 
    18631891 
     
    18651893 
    18661894        label = new QLabel("Filter size"); 
    1867         vbox->layout()->addWidget(label); 
     1895        vl->addWidget(label); 
    18681896 
    18691897        slider = new QSlider(Qt::Horizontal, vbox); 
    1870         vbox->layout()->addWidget(slider); 
     1898        vl->addWidget(slider); 
    18711899        slider->show(); 
    18721900        slider->setRange(1, 100); 
     
    18791907 
    18801908 
    1881         ////////////////////////////////////////// 
    1882  
    1883         label = new QLabel("Spatial Filter size"); 
    1884         vbox->layout()->addWidget(label); 
    1885  
    1886         slider = new QSlider(Qt::Horizontal, vbox); 
    1887         vbox->layout()->addWidget(slider); 
    1888         slider->show(); 
    1889         slider->setRange(1, 100); 
    1890         slider->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Preferred); 
    1891         slider->setValue(10); 
    1892  
    1893         connect(slider, SIGNAL(valueChanged(int)), SIGNAL(SetSpatialFilterSize(int))); 
    1894  
    1895  
     1909         
    18961910        /////////////////////////////////// 
    18971911 
    18981912 
    1899         QWidget *hbox = new QWidget(vbox); 
     1913        QWidget *hbox = new QWidget();//vbox); 
    19001914        vl->addWidget(hbox); 
    19011915        QHBoxLayout *hlayout = new QHBoxLayout; 
     
    19061920        cb->setChecked(false); 
    19071921        connect(cb, SIGNAL(toggled(bool)), SIGNAL(SetShowViewCells(bool))); 
    1908  
     1922         
     1923        cb = new QCheckBox("Render errors", hbox); 
     1924        hlayout->layout()->addWidget(cb); 
     1925        cb->setChecked(false); 
     1926        connect(cb, SIGNAL(toggled(bool)), SIGNAL(SetRenderErrors(bool))); 
     1927 
     1928#if REMOVE_TEMPORARY 
    19091929        cb = new QCheckBox("Render cost curve", hbox); 
    19101930        hlayout->addWidget(cb); 
    19111931        cb->setChecked(false); 
    19121932        connect(cb, SIGNAL(toggled(bool)), SIGNAL(SetShowRenderCost(bool))); 
    1913  
     1933#endif 
    19141934        cb = new QCheckBox("Show rays", hbox); 
    19151935        hlayout->addWidget(cb); 
    19161936        cb->setChecked(false); 
    19171937        connect(cb, SIGNAL(toggled(bool)), SIGNAL(SetShowRays(bool))); 
    1918          
     1938#if REMOVE_TEMPORARY     
    19191939        cb = new QCheckBox("Show Comparison", hbox); 
    19201940        hlayout->addWidget(cb); 
    19211941        cb->setChecked(false); 
    19221942        connect(cb, SIGNAL(toggled(bool)), SIGNAL(SetShowComparison(bool))); 
    1923  
     1943#endif 
    19241944 
    19251945        ////////////////// 
     
    19341954        QGroupBox *groupBox = CreateVisualizationPanel(hbox); 
    19351955        vh->addWidget(groupBox, 0, 0); 
    1936  
     1956#if REMOVE_TEMPORARY 
    19371957        QGroupBox *groupBox2 = CreateRenderCostPanel(hbox); 
    19381958        vh->addWidget(groupBox2, 0, 0); 
    1939          
     1959#endif 
    19401960        QGroupBox *groupBox3 = CreateRayVisualizationPanel(hbox); 
    19411961        vh->addWidget(groupBox3, 0, 0); 
     
    19481968 
    19491969        /*cb = new QRadiobox("Top View", vbox); 
    1950         vbox->layout()->addWidget(cb); 
     1970        vl->addWidget(cb); 
    19511971        cb->setChecked(false); 
    19521972        connect(cb, SIGNAL(toggled(bool)), SIGNAL(SetTopView(bool))); 
    19531973*/ 
    19541974 
    1955         vbox->resize(800,150); 
     1975        //vbox->resize(800,150); 
     1976        QWidget *vbox; 
    19561977 
    19571978        vbox = new QGroupBox("Rendering", this); 
     
    20222043 
    20232044        /////////////////////////////////////////// 
    2024  
     2045#if REMOVE_TEMPORARY 
    20252046        cb = new QCheckBox("Transparency", vbox); 
    20262047        vbox->layout()->addWidget(cb); 
     
    20382059        slider->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Preferred); 
    20392060        slider->setValue(0); 
    2040  
     2061#endif 
    20412062        connect(slider, SIGNAL(valueChanged(int)), SIGNAL(SetTransparency(int))); 
    20422063 
     
    20482069        cb->setChecked(false); 
    20492070        connect(cb, SIGNAL(toggled(bool)), SIGNAL(SetCutScene(bool))); 
    2050 #endif 
     2071 
    20512072        cb = new QCheckBox("Render boxes", vbox); 
    20522073        vbox->layout()->addWidget(cb); 
     
    20582079        cb->setChecked(false); 
    20592080        connect(cb, SIGNAL(toggled(bool)), SIGNAL(SetRenderVisibilityEstimates(bool))); 
    2060  
    2061  
    2062         cb = new QCheckBox("Render errors", vbox); 
    2063         vbox->layout()->addWidget(cb); 
    2064         cb->setChecked(false); 
    2065         connect(cb, SIGNAL(toggled(bool)), SIGNAL(SetRenderErrors(bool))); 
     2081#endif 
    20662082 
    20672083        bool tmp; 
     
    20812097        cb->setChecked(tmp); 
    20822098        connect(cb, SIGNAL(toggled(bool)), SIGNAL(SetUseSpatialFilter(bool))); 
    2083  
     2099#if REMOVE_TEMPORARY 
    20842100        cb = new QCheckBox("Render filter", vbox); 
    20852101        vbox->layout()->addWidget(cb); 
     
    21132129        vbox->layout()->addWidget(button); 
    21142130        connect(button, SIGNAL(clicked()), SIGNAL(LoadObject())); 
    2115  
     2131#endif 
    21162132        /*cb = new QCheckBox("Stats", vbox); 
    21172133        vbox->layout()->addWidget(cb); 
     
    21422158        //connect(button, SIGNAL(clicked(void)), SLOT(StoreStatistics(void))); 
    21432159        //mHidingCost = 0.1f; 
     2160////////////////////////////////////////// 
     2161 
     2162        label = new QLabel("Spatial Filter size"); 
     2163        vbox->layout()->addWidget(label); 
     2164 
     2165        slider = new QSlider(Qt::Horizontal, vbox); 
     2166        vbox->layout()->addWidget(slider); 
     2167        slider->show(); 
     2168        slider->setRange(1, 100); 
     2169        slider->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Preferred); 
     2170        slider->setValue(10); 
     2171 
     2172        connect(slider, SIGNAL(valueChanged(int)), SIGNAL(SetSpatialFilterSize(int))); 
     2173 
    21442174 
    21452175        setWindowTitle("Preprocessor Control Widget"); 
  • GTP/trunk/Lib/Vis/Preprocessing/src/QtInterface/QtGlRenderer.h

    r2614 r2615  
    232232 
    233233        bool mUseRandomColorPerPvsObject; 
    234  
     234#if DYNAMIC_OBJECTS_HACK 
    235235        DynamicObjectsContainer mDynamicObjects; 
    236  
     236#endif 
    237237        QtGlRendererWidget(SceneGraph *sceneGraph, 
    238238                               ViewCellsManager *viewcells, 
  • GTP/trunk/Lib/Vis/Preprocessing/src/QtInterface/QtGlViewer.cpp

    r2614 r2615  
    3131        mModelMatrix = IdentityMatrix(); 
    3232 
     33        //setWindowTitle("PVS visualization"); 
     34        setWindowTitle("Global View Cell Visualization"); 
     35 
    3336        trackball(manipulatorLastQuat, 0.0f, 0.0f, 0.0f, 0.0f); 
    3437        //connect(renderer, SIGNAL(PvsUpdated()), this, SLOT(updateGL())); 
     
    4649QSize QtGlViewer::sizeHint() const  
    4750{ 
    48         return QSize(640, 480); 
     51        // set viewer size here 
     52        return QSize(512, 320); 
     53 
     54        //return QSize(512, 384); 
     55        //return QSize(640, 480); 
    4956} 
    5057   
     
    228235{ 
    229236  switch (e->key()) { 
     237  case Qt::Key_V: 
     238                mRenderer->mRenderViewCells = !mRenderer->mRenderViewCells; 
     239                updateGL(); 
     240                break; 
     241 
    230242  case Qt::Key_W: 
    231243                mWireframe = !mWireframe; 
    232244                updateGL(); 
     245                break; 
     246 
    233247  default: 
    234248                e->ignore(); 
  • GTP/trunk/Lib/Vis/Preprocessing/src/SceneGraph.cpp

    r2610 r2615  
    55#include "X3dExporter.h" 
    66#include "Intersectable.h" 
     7#include "IntersectableWrapper.h" 
    78 
    89 
     
    223224        { 
    224225                (*ni)->UpdateBox(); 
    225                 box.Include((*ni)->mBox); 
     226                box.Include((*ni)->GetBox()); 
    226227        } 
    227228 
     
    277278 
    278279 
    279 void SceneGraphLeaf::Transform(const Matrix4x4 &trafo) 
    280 { 
    281         mTrafo *= trafo; 
    282 } 
    283  
    284 } 
     280SceneGraphLeaf::SceneGraphLeaf(): mIsDynamic(false) 
     281{ 
     282        mTrafo = IdentityMatrix(); 
     283#if DYNAMIC_OBJECTS_HACK 
     284        mIntersectable = new SceneGraphLeafIntersectable(this, mBox); 
     285#endif 
     286} 
     287 
     288 
     289SceneGraphLeaf::SceneGraphLeaf(bool isDynamic): mIsDynamic(isDynamic) 
     290{ 
     291        mTrafo = IdentityMatrix(); 
     292} 
     293 
     294 
     295void SceneGraphLeaf::ApplyTransform(const Matrix4x4 &trafo) 
     296{ 
     297        mTrafo = trafo * mTrafo; 
     298} 
     299 
     300 
     301void SceneGraphLeaf::LoadTransform(const Matrix4x4 &m) 
     302{ 
     303        mTrafo = m; 
     304} 
     305 
     306 
     307void SceneGraphLeaf::GetTransform(Matrix4x4 &m) const 
     308{ 
     309        m = mTrafo; 
     310} 
     311 
     312 
     313AxisAlignedBox3 SceneGraphLeaf::GetBox() const  
     314{ 
     315        return Transform(mBox, mTrafo); 
     316} 
     317 
     318} 
  • GTP/trunk/Lib/Vis/Preprocessing/src/SceneGraph.h

    r2610 r2615  
    99namespace GtpVisibilityPreprocessor { 
    1010 
     11class SceneGraphLeafIntersectable; 
    1112 
    1213/** Basic scene graph node, we are interested only in bounding boxes and topology 
     
    2223        virtual void UpdateBox() = 0; 
    2324 
    24 //protected: 
     25        virtual AxisAlignedBox3 GetBox() const { return mBox; } 
     26 
     27protected: 
    2528 
    2629        AxisAlignedBox3 mBox; 
     
    5154public: 
    5255 
    53         SceneGraphLeaf(bool isDynamic = false):  
    54           mIsDynamic(isDynamic){} 
     56        SceneGraphLeaf(); 
     57        SceneGraphLeaf(bool isDynamic); 
    5558        ~SceneGraphLeaf(); 
     59         
     60        void LoadTransform(const Matrix4x4 &m); 
    5661 
    57         virtual void Transform(const Matrix4x4 &trafo); 
     62        void GetTransform(Matrix4x4 &m) const; 
     63 
     64        virtual AxisAlignedBox3 GetBox() const; 
     65 
     66        virtual void ApplyTransform(const Matrix4x4 &trafo); 
    5867        virtual bool IsDynamic() const { return mIsDynamic;} 
    5968        virtual bool IsLeaf() const { return true; } 
    6069        virtual void UpdateBox(); 
    61  
     70#if DYNAMIC_OBJECT_HACK 
     71        SceneGraphLeafIntersectable *GetIntersectable() { return mIntersectable;} 
     72#endif 
     73        /// used as actual pvs entry 
    6274        ObjectContainer mGeometry; 
    6375 
    6476protected: 
    65  
     77#if DYNAMIC_OBJECT_HACK 
     78        SceneGraphLeafIntersectable *mIntersectable; 
     79#endif 
    6680        bool mIsDynamic; 
    6781        Matrix4x4 mTrafo; 
     
    88102        void GetStatistics(int &intersectables, int &faces) const; 
    89103 
    90         AxisAlignedBox3 GetBox() const { return mRoot->mBox; } 
     104        AxisAlignedBox3 GetBox() const { return mRoot->GetBox(); } 
    91105        /** Exports binary version of the scene. 
    92106        */ 
  • GTP/trunk/Lib/Vis/Preprocessing/src/ViewCellsManager.cpp

    r2614 r2615  
    369369{ 
    370370#if DYNAMIC_OBJECTS_HACK 
     371 
     372#if USE_TRANSFORMED_MESH_INSTANCE_HACK 
    371373        if (ray.mTerminationObject->Type() == Intersectable::TRANSFORMED_MESH_INSTANCE) 
    372374                return ray.mTerminationObject; 
     375#else 
     376        if (ray.mTerminationObject->Type() == Intersectable::SCENEGRAPHLEAF_INTERSECTABLE) 
     377                return ray.mTerminationObject; 
     378#endif 
     379 
    373380#endif 
    374381        if (mUseKdPvs) 
     
    33593366                        // $$ warning collect objects takes only unmailed ones! 
    33603367                        if (mUseKdPvs) { 
    3361                           //                      GetPreprocessor()->mKdTree->CollectKdObjects(box, objects); 
    3362                           GetPreprocessor()->mKdTree->CollectSmallKdObjects(box, objects, 0.1f); 
     3368                                                  GetPreprocessor()->mKdTree->CollectKdObjects(box, objects); 
     3369                          //GetPreprocessor()->mKdTree->CollectSmallKdObjects(box, objects, 0.1f); 
    33633370 
    33643371                        } else 
     
    33703377                          { 
    33713378                                Intersectable *o = *noi; 
     3379                                 
    33723380                                // $$ JB warning: pdfs are not correct at this point!      
    33733381                                pvs.AddSampleDirty(o, Limits::Small); 
  • GTP/trunk/Lib/Vis/Preprocessing/src/common.h

    r2609 r2615  
    2323#include <vector> 
    2424 
    25 #define DYNAMIC_OBJECTS_HACK 1 
     25#define DYNAMIC_OBJECTS_HACK 0 
     26#define USE_TRANSFORMED_MESH_INSTANCE_HACK 1 
    2627#define USE_HAVRAN_RAYCASTER 
    2728 
  • GTP/trunk/Lib/Vis/Preprocessing/src/main.cpp

    r2611 r2615  
    348348                        rendererWidget->Show(); 
    349349 
     350                        //rendererWidget->SetWindowTitle("Global Visualization"); 
     351 
    350352                        if (1) // not working with vbo 
    351353                        { 
Note: See TracChangeset for help on using the changeset viewer.