]> git.sesse.net Git - mlt/commitdiff
Fix regression on scaling alpha channel.
authorDan Dennedy <dan@dennedy.org>
Sun, 29 Aug 2010 19:01:32 +0000 (12:01 -0700)
committerDan Dennedy <dan@dennedy.org>
Sun, 29 Aug 2010 19:01:32 +0000 (12:01 -0700)
Regression introduced with usage of sws_getCachedContext not too long
ago.

src/modules/avformat/filter_swscale.c

index 3f53f620ac2d6db9639bc4f20ec6a63deab0fc0a..71972dc4a277ef667d0a7bb5c10d1aa1d6a08448 100644 (file)
@@ -180,8 +180,7 @@ static int filter_scale( mlt_frame this, uint8_t **image, mlt_image_format *form
                                avpicture_fill( &output, outbuf, avformat, owidth, oheight );
        
                                // Perform the scaling
-                               sws_scale( context, input.data, input.linesize, 0, iheight, output.data, output.linesize);
-                               sws_freeContext( context );
+                               sws_scale( new_context, input.data, input.linesize, 0, iheight, output.data, output.linesize);
        
                                // Set it back on the frame
                                mlt_properties_set_data( MLT_FRAME_PROPERTIES( this ), "alpha", output.data[0], owidth * oheight, mlt_pool_release, NULL );