Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

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


Ignore:
Timestamp:
Jul 14, 2005, 12:46:12 AM (19 years ago)
Author:
patrick
Message:

orxonox/trunk: implemented a first draw function and some commented separation propagation

File:
1 edited

Legend:

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

    r4855 r4859  
    189189    }
    190190
     191  /* now do cleanup */
     192  delete listA;
     193  delete listB;
     194  delete listC;
     195  delete listD;
     196  delete iterator;
     197
     198  /* now propagate */
     199  /*
     200  this->nodeA = new QuadtreeNode(pTriA, lenA, this->quadtree);
     201  this->nodeA->separate();
     202
     203  this->nodeB = new QuadtreeNode(pTriB, lenB, this->quadtree);
     204  this->nodeB->separate();
     205
     206  this->nodeC = new QuadtreeNode(pTriC, lenC, this->quadtree);
     207  this->nodeC->separate();
     208
     209  this->nodeD = new QuadtreeNode(pTriD, lenD, this->quadtree);
     210  this->nodeD->separate();
     211  */
     212
    191213  PRINTF(0)("separation complete\n");
    192214}
     
    198220 */
    199221void QuadtreeNode::drawTree(int depth, int drawMode) const
    200 {}
     222{
     223
     224  Vector t1 = *this->pDimension->getCenter();
     225  float ax = this->pDimension->getAxis();
     226  float h = 0.0f;
     227
     228  glBegin(GL_QUADS);
     229  glVertex3f(t1.x + ax, h, t1.z + ax);
     230  glVertex3f(t1.x - ax, h, t1.z + ax);
     231  glVertex3f(t1.x - ax, h, t1.z - ax);
     232  glVertex3f(t1.x + ax, h, t1.z - ax);
     233  glEnd();
     234}
    201235
    202236
Note: See TracChangeset for help on using the changeset viewer.