[FFmpeg-devel] [PATCH] FATE: Add test for libavfilter/scale2ref

Gyan gyandoshi at gmail.com
Sun Jun 4 11:19:49 EEST 2017

On Sun, Jun 4, 2017 at 1:23 PM, Kevin Mark <kmark937 at gmail.com> wrote:

> If we were to use "iw/4:-1" in place of "iw/4:ow/mdar":
> 640 / 4 = 160. So the new width for [main] would be 160.
> 360 / 4 = 90. So the new height for [main] would be 90.
> 160 / 90 = 16 / 9 so [main] now has the same aspect ratio as [ref]
> which is probably what you do not want.

 Now that this feature has been applied, it may be helpful to check if one
of the W/H arguments is of the form '-n' and log a warning that this will
force the ref's display aspect ratio. The warning should also convey the
expression to use: 'oh*mdar' or 'ow/mdar' , as the case may be.

Additionally, since the output SAR will be adjusted to force the ref's DAR,
it would be helpful to add a warning for that (tell users to append
setsar=1 after the scale)  --or--  (ideally) patch the filter so that the
main's DAR is preserved.

More information about the ffmpeg-devel mailing list