From: Carl Hetherington Date: Mon, 1 Feb 2016 20:23:08 +0000 (+0000) Subject: Scale-to-fit-{width/height} should zero the 'other' crop values. X-Git-Tag: v2.6.18~5^2 X-Git-Url: https://git.carlh.net/gitweb/?p=dcpomatic.git;a=commitdiff_plain;h=4bc431e9d9dc490560d376b1b6efb4e67c6cfb54 Scale-to-fit-{width/height} should zero the 'other' crop values. --- diff --git a/src/lib/video_content.cc b/src/lib/video_content.cc index d104004f2..fcf7e3229 100644 --- a/src/lib/video_content.cc +++ b/src/lib/video_content.cc @@ -461,6 +461,8 @@ VideoContent::scale_and_crop_to_fit_width () set_scale (VideoContentScale (film()->container ())); int const crop = max (0, int (video_size().height - double (film()->frame_size().height) * video_size().width / film()->frame_size().width)); + set_left_crop (0); + set_right_crop (0); set_top_crop (crop / 2); set_bottom_crop (crop / 2); } @@ -473,6 +475,8 @@ VideoContent::scale_and_crop_to_fit_height () int const crop = max (0, int (video_size().width - double (film()->frame_size().width) * video_size().height / film()->frame_size().height)); set_left_crop (crop / 2); set_right_crop (crop / 2); + set_top_crop (0); + set_bottom_crop (0); } void