Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 4580 in orxonox.OLD for orxonox/trunk


Ignore:
Timestamp:
Jun 10, 2005, 3:13:40 AM (19 years ago)
Author:
bensch
Message:

orxonox/trunk: arrays of Models get stored till the end

Location:
orxonox/trunk/src/lib/graphics/importer
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/lib/graphics/importer/array.h

    r4579 r4580  
    6767  this->firstEntry = new Entry;
    6868  this->firstEntry->next =NULL;
    69   this->currentEntry=firstEntry;
     69  this->currentEntry = this->firstEntry;
    7070  this->finalized = false;
    7171  this->entryCount = 0; //0 means one entry
     
    109109    walker = walker->next;
    110110  }
     111  walker = this->firstEntry;
     112  Entry* previous;
     113  while (walker)
     114  {
     115    previous = walker;
     116    walker = walker->next;
     117    delete previous;
     118  }
     119  this->firstEntry = NULL;
    111120  this->finalized = true;
    112121}
     
    130139  }
    131140  else
    132     PRINTF(2)("adding failed, because list has been finalized\n");
     141    PRINTF(2)("adding failed, because array has already been finalized\n");
    133142}
    134143
  • orxonox/trunk/src/lib/graphics/importer/model.cc

    r4579 r4580  
    176176  delete this->firstGroup;
    177177
    178   // deleting Arrays
     178  // deleting Arrays (if not allready done by finalize)
    179179  this->deleteArrays();
    180180
     
    203203
    204204  // deletes everything we allocated.
    205   if (this->type == MODEL_DISPLAY_LIST)
    206     this->deleteArrays();
     205  //if (this->type == MODEL_DISPLAY_LIST)
     206    //this->deleteArrays();
    207207  this->cleanup();
    208208
Note: See TracChangeset for help on using the changeset viewer.