From f517ca454289d16fe429c12ef34776006396a33b Mon Sep 17 00:00:00 2001 From: Dan Dennedy Date: Sun, 27 Mar 2011 19:13:55 -0700 Subject: [PATCH] Fix composite using wrong B frame scaling. This could happen when the caller of mlt_frame_get_image supplied 0 for width and height. For example, Kdenlive's GL output with the sdl_audio consumer with real_time > 1 and paused. --- src/modules/core/transition_composite.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/modules/core/transition_composite.c b/src/modules/core/transition_composite.c index 45683683..811ee8d3 100644 --- a/src/modules/core/transition_composite.c +++ b/src/modules/core/transition_composite.c @@ -1120,8 +1120,8 @@ static int transition_get_image( mlt_frame a_frame, uint8_t **image, mlt_image_f // Get the image from the b frame uint8_t *image_b = NULL; - int width_b = *width; - int height_b = *height; + int width_b = *width > 0 ? *width : mlt_properties_get_int( a_props, "normalised_width" ); + int height_b = *height > 0 ? *height : mlt_properties_get_int( a_props, "normalised_height" ); // Vars for alphas uint8_t *alpha_a = NULL; -- 2.39.2