]> git.tdb.fi Git - libs/gl.git/commitdiff
Fix TexGen unbinding
authorMikko Rasa <tdb@tdb.fi>
Sun, 28 Sep 2014 18:07:33 +0000 (21:07 +0300)
committerMikko Rasa <tdb@tdb.fi>
Mon, 29 Sep 2014 15:10:05 +0000 (18:10 +0300)
source/texgen.cpp

index 0114b2b73e2af6cbb177fc7aaeb5bb8613489f60..4310d19a6cbfea8f2f82201997560b5d25c76e5c 100644 (file)
@@ -51,7 +51,10 @@ void TexGen::unbind_from(unsigned i, TexCoordComponent c)
 {
        TexUnit &unit = TexUnit::get_unit(i);
        if(unit.set_texgen(coord_index(c), 0))
+       {
+               unit.bind();
                disable(GL_TEXTURE_GEN_S+coord_index(c));
+       }
 }
 
 unsigned TexGen::coord_index(TexCoordComponent c)