]> git.sesse.net Git - mlt/blobdiff - src/modules/opengl/filter_glsl_manager.cpp
A little debugging.
[mlt] / src / modules / opengl / filter_glsl_manager.cpp
index 0fd62853e39af66df3f29ad86ec33a9f48ec0061..b2a31a6fa2697455b05d0df55e08583d33dfc658 100644 (file)
@@ -133,6 +133,7 @@ glsl_texture GlslManager::get_texture(int width, int height, GLint internal_form
                return NULL;
        }
 
+       printf("created a new texture for %dx%d: %d\n", width, height, tex);
        glBindTexture( GL_TEXTURE_2D, tex );
        glTexImage2D( GL_TEXTURE_2D, 0, internal_format, width, height, 0, GL_RGBA, GL_UNSIGNED_BYTE, NULL );
     glTexParameterf( GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE );
@@ -225,7 +226,7 @@ void GlslManager::onInit( mlt_properties owner, GlslManager* filter )
 #else
        std::string path = std::string(getenv("MLT_MOVIT_PATH") ? getenv("MLT_MOVIT_PATH") : SHADERDIR);
 #endif
-       bool success = init_movit( path, mlt_log_get_level() == MLT_LOG_DEBUG? MOVIT_DEBUG_ON : MOVIT_DEBUG_OFF );
+       bool success = init_movit( path, MOVIT_DEBUG_ON );
        filter->set( "glsl_supported", success );
 }
 
@@ -356,6 +357,18 @@ void GlslManager::set_effect_secondary_input( mlt_service service, mlt_frame fra
        set_frame_specific_data( service, frame, "_movit effect secondary input frame", input_frame, 0, NULL, NULL );
 }
 
+void GlslManager::get_effect_third_input( mlt_service service, mlt_frame frame, mlt_service *input_service, mlt_frame *input_frame)
+{
+       *input_service = (mlt_service) get_frame_specific_data( service, frame, "_movit effect third input", NULL );
+       *input_frame = (mlt_frame) get_frame_specific_data( service, frame, "_movit effect third input frame", NULL );
+}
+
+void GlslManager::set_effect_third_input( mlt_service service, mlt_frame frame, mlt_service input_service, mlt_frame input_frame )
+{
+       set_frame_specific_data( service, frame, "_movit effect third input", input_service, 0, NULL, NULL );
+       set_frame_specific_data( service, frame, "_movit effect third input frame", input_frame, 0, NULL, NULL );
+}
+
 int GlslManager::render_frame_texture(EffectChain *chain, mlt_frame frame, int width, int height, uint8_t **image)
 {
        glsl_texture texture = get_texture( width, height, GL_RGBA8 );