Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jul 20, 2005, 9:33:10 PM (19 years ago)
Author:
patrick
Message:

orxonox/trunk: hash table preparation for quadtree nodes lookup

File:
1 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/lib/graphics/spatial_separation/quadtree.cc

    r4902 r4907  
    3333   this->treeDepth = treeDepth;
    3434
     35   /* initialize the materials for debug draw */
    3536   this->materials = new Material*[4];
    3637   for(int i = 0; i < 4; ++i)
     
    4445   materials[3]->setAmbient(5.0, 3.0, 1.0);
    4546
     47   /* build the tree */
     48   this->rootNode = new QuadtreeNode(this->pModelInfo, this, this->treeDepth);
    4649
    47    this->rootNode = new QuadtreeNode(this->pModelInfo, this, this->treeDepth);
     50   /* make an array with access to the leafs of the Quad-Tree */
     51   this->nodes = new QuadtreeNode*[(int)pow(4, treeDepth)];
    4852}
    4953
     
    5660{
    5761  // delete what has to be deleted here
     62  delete [] this->nodes;
     63  delete this->rootNode;
    5864}
    5965
Note: See TracChangeset for help on using the changeset viewer.