X-Git-Url: http://research.m1stereo.tv/gitweb?a=blobdiff_plain;f=src%2Fmodules%2Fcore%2Ftransition_luma.c;fp=src%2Fmodules%2Fcore%2Ftransition_luma.c;h=2f4b17d693cf1d785932b57cd50fb6e06dfbd0dc;hb=e4c309088914627f82a005eeb96e303dbdd7882a;hp=e55046cf26826fb595ef36ba097f437a96a87e53;hpb=0613834daf55868e80bf7655ad4012e29ebcf4dd;p=melted diff --git a/src/modules/core/transition_luma.c b/src/modules/core/transition_luma.c index e55046c..2f4b17d 100644 --- a/src/modules/core/transition_luma.c +++ b/src/modules/core/transition_luma.c @@ -369,6 +369,9 @@ static int transition_get_image( mlt_frame a_frame, uint8_t **image, mlt_image_f // Get the properties of the b frame mlt_properties b_props = MLT_FRAME_PROPERTIES( b_frame ); + // This compositer is yuv422 only + *format = mlt_image_yuv422; + // The cached luma map information int luma_width = mlt_properties_get_int( properties, "width" ); int luma_height = mlt_properties_get_int( properties, "height" ); @@ -512,6 +515,7 @@ static int transition_get_image( mlt_frame a_frame, uint8_t **image, mlt_image_f if ( mlt_properties_get( properties, "fixed" ) ) mix = mlt_properties_get_double( properties, "fixed" ); + if ( luma_width > 0 && luma_height > 0 && luma_bitmap != NULL ) // Composite the frames using a luma map luma_composite( !invert ? a_frame : b_frame, !invert ? b_frame : a_frame, luma_width, luma_height, luma_bitmap, mix, frame_delta, @@ -520,6 +524,7 @@ static int transition_get_image( mlt_frame a_frame, uint8_t **image, mlt_image_f // Dissolve the frames using the time offset for mix value dissolve_yuv( a_frame, b_frame, mix, *width, *height ); + // Extract the a_frame image info *width = mlt_properties_get_int( !invert ? a_props : b_props, "width" ); *height = mlt_properties_get_int( !invert ? a_props : b_props, "height" );