Changeset 9785 in orxonox.OLD for branches/new_class_id/src/lib/graphics/importer/material.cc
- Timestamp:
- Sep 22, 2006, 3:40:06 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/new_class_id/src/lib/graphics/importer/material.cc
r9718 r9785 25 25 #include "loading/load_param.h" 26 26 27 #include "util/loading/resource_manager.h" 27 #include "resource_texture.h" 28 //#include "util/loading/resource_manager.h" 28 29 29 30 ObjectListDefinition(Material); … … 91 92 { 92 93 PRINTF(5)("delete Material %s.\n", this->getCName()); 93 94 if (this->ambientTexture != NULL)95 ResourceManager::getInstance()->unload(this->ambientTexture);96 if (this->specularTexture != NULL)97 ResourceManager::getInstance()->unload(this->specularTexture);98 94 99 95 if (this == Material::selectedMaterial) … … 297 293 void Material::addTexturePath(const std::string& pathName) 298 294 { 299 ResourceManager::getInstance()->addImageDir(pathName); 295 printf("HUPS\n"); 296 //ResourceManager::getInstance()->addImageDir(pathName); 300 297 } 301 298 … … 351 348 if (!dMap.empty()) 352 349 { 353 Texture* tex = dynamic_cast<Texture*>(ResourceManager::getInstance()->load(dMap, IMAGE, RP_GAME, (int)target)); 354 if (tex != NULL) 355 this->textures[textureNumber] = *tex; 350 this->textures[textureNumber] = ResourceTexture(dMap); 351 //dynamic_cast<Texture*>(ResourceManager::getInstance()->load(dMap, IMAGE, RP_GAME, (int)target)); 352 /* if (tex != NULL) 353 this->textures[textureNumber] = tex; 356 354 else 357 this->textures[textureNumber] = Texture(); 355 this->textures[textureNumber] = Texture();*/ 358 356 } 359 357 else
Note: See TracChangeset
for help on using the changeset viewer.