X-Git-Url: http://research.m1stereo.tv/gitweb?a=blobdiff_plain;f=src%2Fmodules%2Fcore%2Ftransition_composite.c;h=04a518f53b569297a019abe0e8b42e71cbdae34d;hb=42eea21bf0c71036397cac39f19d537c9344081c;hp=3725c4a62c548f0c32dd745e4ae9ab3426674a5d;hpb=fffd43713488179eeb1770d2d94ec0177252fef5;p=melted diff --git a/src/modules/core/transition_composite.c b/src/modules/core/transition_composite.c index 3725c4a..04a518f 100644 --- a/src/modules/core/transition_composite.c +++ b/src/modules/core/transition_composite.c @@ -201,7 +201,7 @@ static inline double delta_calculate( mlt_transition this, mlt_frame frame, mlt_ return length * ( y - x ) / 2.0; } -static int get_value( mlt_properties properties, char *preferred, char *fallback ) +static int get_value( mlt_properties properties, const char *preferred, const char *fallback ) { int value = mlt_properties_get_int( properties, preferred ); if ( value == 0 ) @@ -648,6 +648,15 @@ static uint16_t* get_luma( mlt_transition this, mlt_properties properties, int w luma_bitmap = NULL; } } + else { + char *old_luma = mlt_properties_get( properties, "_luma" ); + if ( old_luma && old_luma[0] ) + { + mlt_properties_set_data( properties, "_luma.orig_bitmap", NULL, 0, NULL, NULL ); + luma_bitmap = NULL; + mlt_properties_set( properties, "_luma", NULL); + } + } if ( resource && resource[0] && ( luma_bitmap == NULL || luma_width != width || luma_height != height ) ) { @@ -1129,7 +1138,7 @@ static int transition_get_image( mlt_frame a_frame, uint8_t **image, mlt_image_f uint8_t *alpha_b = NULL; // Composites always need scaling... defaulting to lowest - char *rescale = mlt_properties_get( a_props, "rescale.interp" ); + const char *rescale = mlt_properties_get( a_props, "rescale.interp" ); if ( rescale == NULL || !strcmp( rescale, "none" ) ) rescale = "nearest"; mlt_properties_set( a_props, "rescale.interp", rescale );