X-Git-Url: https://git.verplant.org/?a=blobdiff_plain;f=src%2Fvideo%2Ftexture_manager.cpp;h=d9ff2a74be2ee1c1c1af3fac2184980033117ff5;hb=8c205abd2d811ba36e1a3639f5bfab6263bf9077;hp=7b556a64244442a0e7e3d31adffce28bcb938748;hpb=20efd7620620892d92b1c7df124c3a0c8df22a82;p=supertux.git diff --git a/src/video/texture_manager.cpp b/src/video/texture_manager.cpp index 7b556a642..d9ff2a74b 100644 --- a/src/video/texture_manager.cpp +++ b/src/video/texture_manager.cpp @@ -28,12 +28,13 @@ #include #include #include "physfs/physfs_sdl.hpp" +#include "video_systems.hpp" #include "gl_texture.hpp" -#include "sdl_texture.hpp" #include "glutil.hpp" #include "gameconfig.hpp" #include "file_system.hpp" #include "log.hpp" +#include "texture.hpp" TextureManager* texture_manager = NULL; @@ -103,16 +104,7 @@ TextureManager::create_image_texture(const std::string& filename) Texture* result = 0; try { -#ifdef HAVE_OPENGL - if(config->video == "opengl") - { - result = new GL::Texture(image); - } - else -#endif - { - result = new SDL::Texture(image); - } + result = new_texture(image); result->set_filename(filename); } catch(...) { delete result;