]> git.tdb.fi Git - libs/gl.git/blobdiff - source/core/texture.cpp
Allow renderables to be specified in SequenceTemplate passes
[libs/gl.git] / source / core / texture.cpp
index f6594ab14c7e5143434ac0823c862427c70f2c9d..3a4b1096f99cb2edee54137194f64cb3b805b808 100644 (file)
@@ -75,7 +75,7 @@ void Texture::set_format(PixelFormat fmt)
        default:;
        }
 
-       PixelFormat st_fmt = make_pixelformat(st_comp, get_component_type(fmt));
+       PixelFormat st_fmt = make_pixelformat(st_comp, get_component_type(fmt), is_srgb(fmt));
        require_pixelformat(st_fmt);
        if(swiz!=NO_SWIZZLE)
                static Require _req(ARB_texture_swizzle);
@@ -287,7 +287,7 @@ void Texture::Loader::init()
        levels = 0;
 
        add("external_image", &Loader::external_image);
-       add("external_image_srgb", &Loader::external_image);
+       add("external_image_srgb", &Loader::external_image_srgb);
        add("filter", &Loader::filter);
        add("generate_mipmap", &Loader::generate_mipmap);
        add("image_data", &Loader::image_data);
@@ -309,7 +309,7 @@ unsigned Texture::Loader::get_levels() const
 
 #pragma GCC diagnostic push
 #pragma GCC diagnostic ignored "-Wdeprecated-declarations"
-void Texture::Loader::load_external_image(Graphics::Image &img, const std::string &fn)
+void Texture::Loader::load_external_image(Graphics::Image &img, const string &fn)
 {
        RefPtr<IO::Seekable> io = get_collection().open_raw(fn);
        if(!io)