Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 5116 in orxonox.OLD for trunk/src/lib


Ignore:
Timestamp:
Aug 24, 2005, 1:47:05 AM (19 years ago)
Author:
bensch
Message:

orxonox/trunk: saver removal of vertices in obb's

Location:
trunk/src/lib/collision_detection
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/lib/collision_detection/bounding_volume.cc

    r4836 r5116  
    2929   this->setClassID(CL_BOUNDING_VOLUME, "BoundingVolume");
    3030   this->center = new Vector();
    31    this->bOrigVertices = false;
     31   this->bOrigVertices = true;
    3232}
    3333
     
    4141  // delete what has to be deleted here
    4242  delete this->center;
     43
     44  if( this->vertices && !this->bOrigVertices)
     45  {
     46    delete this->vertices;
     47    this->vertices = NULL;
     48  }
    4349}
  • trunk/src/lib/collision_detection/cd_engine.cc

    r5115 r5116  
    100100        ////////////////
    101101
    102 /*                if( likely(entity2 != this->terrain))
     102/*        if( likely(entity2 != this->terrain))
    103103        {
    104104          PRINTF(4)("checking object %s against %s\n", entity1->getName(), entity2->getName());
     
    108108        entity2 = iterator2->nextElement();
    109109      }
    110 //      printf("\n");
     110    //  printf("\n");
    111111    }
    112112    entity1 = iterator1->nextElement();
  • trunk/src/lib/collision_detection/obb.cc

    r4836 r5116  
    4444  delete [] this->axis;
    4545  delete [] this->halfLength;
    46 
    47   if( this->vertices && !this->bOrigVertices)
    48   {
    49     delete this->vertices;
    50     this->vertices = NULL;
    51   }
    5246}
    5347
Note: See TracChangeset for help on using the changeset viewer.