X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Ftexture3d.cpp;h=48b358c2edd2ad0e2a899138713b8bb5d82135c9;hb=47f817343df1d06d91a4f7c4d5b47df40b24366c;hp=c107fd7451a16a6f2f9c5368e065d20442249277;hpb=aead6d04308d7873dc99aa4572ce1590a89ebcbd;p=libs%2Fgl.git diff --git a/source/texture3d.cpp b/source/texture3d.cpp index c107fd74..48b358c2 100644 --- a/source/texture3d.cpp +++ b/source/texture3d.cpp @@ -190,10 +190,7 @@ void Texture3D::image(const Graphics::Image &img, unsigned lv, bool srgb) PixelFormat fmt = pixelformat_from_graphics(img.get_format()); if(width==0) - { - unsigned l = (is_mipmapped(min_filter) ? lv : 1); - storage(storage_pixelformat_from_graphics(img.get_format(), srgb), w, h, d, l); - } + storage(storage_pixelformat_from_graphics(img.get_format(), srgb), w, h, d, lv); else if(w!=width || h!=height || d!=depth) throw incompatible_data("Texture3D::load_image");