]> git.tdb.fi Git - libs/gl.git/commitdiff
Fix a bug with setting uniforms after texunits
authorMikko Rasa <tdb@tdb.fi>
Mon, 1 Jun 2020 10:11:30 +0000 (13:11 +0300)
committerMikko Rasa <tdb@tdb.fi>
Mon, 1 Jun 2020 21:41:59 +0000 (00:41 +0300)
source/renderpass.cpp

index d2ce1652fa682138bd5592dd7698e7b4b01060d5..0d76913bb3a409248dbbd232b3f5db598bee38b1 100644 (file)
@@ -182,9 +182,7 @@ void RenderPass::Loader::texunit_named(unsigned i, const string &n)
 void RenderPass::Loader::uniforms()
 {
        obj.ensure_private_shader_data();
-       RefPtr<ProgramData> shd = new ProgramData(obj.shprog);
-       load_sub(*shd);
-       obj.shdata = shd.release();
+       load_sub(*obj.shdata);
 }
 
 void RenderPass::Loader::uniform_slot(const string &name)