]> git.sesse.net Git - mlt/blobdiff - src/modules/opengl/filter_glsl_manager.cpp
Take MltInput out of the EffectChain.
[mlt] / src / modules / opengl / filter_glsl_manager.cpp
index 100c3ab1ac420c7a2906872852178a5ed2d987fc..a276f08b1cde5e7c764aeab76e9f5f2e509b50d0 100644 (file)
@@ -326,6 +326,13 @@ mlt_filter filter_glsl_manager_init( mlt_profile profile, mlt_service_type type,
 
 static void deleteChain( GlslChain* chain )
 {
+       // The Input* is owned by the EffectChain, but the MltInput* is not.
+       // Thus, we have to delete it here.
+       for (std::map<mlt_producer, MltInput*>::iterator input_it = chain->inputs.begin();
+            input_it != chain->inputs.end();
+            ++input_it) {
+               delete input_it->second;
+       }
        delete chain->effect_chain;
        delete chain;
 }