if(!texture) {
texture = create_image_texture(filename);
- image_textures[filename] = texture;
+ image_textures[texture->get_filename()] = texture;
}
return texture;
{
log_warning << "Couldn't load texture '" << filename << "' (now using dummy texture): " << err.what() << std::endl;
TexturePtr texture = create_dummy_texture();
+ texture->set_filename(filename);
return texture;
}
}
{
log_warning << "Couldn't load texture '" << filename << "' (now using dummy texture): " << err.what() << std::endl;
TexturePtr texture = create_dummy_texture();
+ texture->set_filename(filename);
return texture;
}
}