Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 10243 in orxonox.OLD


Ignore:
Timestamp:
Jan 17, 2007, 12:26:26 AM (17 years ago)
Author:
patrick
Message:

still on this resource thingy

Location:
branches/mount_points/src
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • branches/mount_points/src/lib/graphics/importer/oif/object_information_file.cc

    r10242 r10243  
    3030OIFData::OIFData()
    3131{
     32  PRINTF(0)("OIFDATA NEW (default)\n");
    3233  this->_root = NULL;
    3334}
     
    4041OIFData::OIFData(const std::string& fileName)
    4142{
    42   this->_root = NULL;
    43 
     43  PRINTF(0)("OIFDATA NEW\n");
    4444  this->load(fileName);
    4545}
     
    5252void OIFData::load(const std::string& fileName)
    5353{
    54   PRINTF(0)("loading |%s| as oif data\n", fileName.c_str());
     54  this->_root = NULL;
     55
    5556  if( fileName.empty())
    5657  {
    57     PRINTF(0)("No filename specified for object information loading");
     58    PRINTF(3)("No filename specified for object information loading");
    5859    return;
    5960  }
     
    6465  {
    6566    // report an error
    66     PRINTF(0)("Could not load XML File %s: %s @ %d:%d\n", fileName.c_str(), XMLDoc.ErrorDesc(), XMLDoc.ErrorRow(), XMLDoc.ErrorCol());
     67    PRINTF(3)("Could not load XML File %s: %s @ %d:%d\n", fileName.c_str(), XMLDoc.ErrorDesc(), XMLDoc.ErrorRow(), XMLDoc.ErrorCol());
    6768    return;
    6869  }
     
    7273  assert( this->_root != NULL);
    7374
     75  PRINTF(0)("%s\n\n\n", this->_root->Value());
    7476  if( strcmp( this->_root->Value(), "ObjectInformationFile"))
    7577  {
    7678    // report an error
    77     PRINTF(0)("Specified XML File is not an orxonox object information file (<ObjectInformationFile> element missing)\n");
     79    PRINTF(3)("Specified XML File is not an orxonox object information file (<ObjectInformationFile> element missing)\n");
    7880    return;
    7981  }
    80   PRINTF(0)("OIF loaded\n");
    81 
    8282}
    8383
  • branches/mount_points/src/lib/graphics/importer/oif/object_information_file.h

    r10241 r10243  
    2626  void load(const std::string& fileName);
    2727
    28   inline TiXmlElement* root() { return this->_root; }
     28  inline const TiXmlElement* root() { return this->_root; }
    2929
    3030
  • branches/mount_points/src/lib/graphics/importer/oif/resource_oif.cc

    r10242 r10243  
    2929  if (ptr)
    3030  {
    31     PRINTF(0)("FOUND OIF: %s\n", fileName.c_str());
     31    PRINTF(5)("FOUND OIF: %s\n", fileName.c_str());
    3232    this->acquireData(static_cast<ResourceOIF::OIFResourcePointer*>(ptr)->ptr());
    3333  }
    3434  else
    3535  {
    36     PRINTF(0)("NOT FOUND OIF: %s\n", fileName.c_str());
     36    PRINTF(5)("NOT FOUND OIF: %s\n", fileName.c_str());
    3737    std::string fullName = this->Resource::locateFile(fileName);
    38     PRINTF(0)("trying loading of: %s\n", fullName.c_str());
     38    PRINTF(5)("trying loading of: %s\n", fullName.c_str());
    3939    this->load(fullName);
    4040    this->Resource::addResource(new ResourceOIF::OIFResourcePointer(fileName, keepLevel, this->ObjectInformationFile::dataPointer()));
  • branches/mount_points/src/world_entities/mount_point.cc

    r10240 r10243  
    7979  if( element == NULL)
    8080  {
    81     PRINTF(1)("Object Information file is missing a proper 'MountPoints' section\n");
     81    PRINTF(1)("I am in section: %s, Object Information file is missing a proper 'MountPoints' section\n", root->Value());
     82//     element = root->FirstChildElement( );
     83//     PRINTF(0)("first child: %s\n", element->Value());
    8284  }
    8385  else
  • branches/mount_points/src/world_entities/world_entity.cc

    r10239 r10243  
    279279void WorldEntity::loadMountPoints( Model* model, const std::string& fileName)
    280280{
    281   PRINTF(4)("loading the oif File: %s\n", fileName.c_str());
     281  PRINTF(0)("loading the oif File: %s\n", fileName.c_str());
    282282
    283283  // now load the object information file
Note: See TracChangeset for help on using the changeset viewer.