crop_scale_window_test leave the 6 pixels at the right side of the image
uninitialised (sws_scale doesn't fill them in with anything) so you get
garbage in the output. SWS_ACCURATE_RND fixes it. There are whisperings
that this is slow, so the impact of this patch may need to be measured
in some "real" situations.
struct SwsContext* scale_context = sws_getContext (
size().width, size().height, pixel_format(),
out_size.width, out_size.height, out_format,
- fast ? SWS_FAST_BILINEAR : SWS_BICUBIC, 0, 0, 0
+ (fast ? SWS_FAST_BILINEAR : SWS_BICUBIC) | SWS_ACCURATE_RND, 0, 0, 0
);
DCPOMATIC_ASSERT (yuv_to_rgb < dcp::YUV_TO_RGB_COUNT);