[FFmpeg-user] ffmpeg MP4/x264 output colours change when input source is different resolution (bug?)

Paul B Mahol onemda at gmail.com
Thu Sep 15 00:53:56 EEST 2022


On 9/14/22, Dan <twinbee42 at skytopia.com> wrote:
>>> Unless I'm somehow misusing zscale (which is a possibility), it would
>>> seem
>>> as if the
>>> problem lies elsewhere.
>>
>> If you do not use format filter after zscale it will not work correctly.
>
> Do you mean using the "filter" keyword under the zscale property/variable?
>
> I tried this, again no luck (also tried filter=point):
>
> ffmpeg.exe -f lavfi -i color=0x19be0f:s=400x578 -crf 0 -vcodec libx264 -vf
> zscale=w=-1:h=-1:filter=lanczos -t 5 -y "578.mp4"
>
> If you would kindly give the appropriate command line, or even just the
> relevant bit of the line
> to make zscale work, that might help save me from flailing around as much
> ;)

zscale=...,format=yuv420p

Here both zscale/scale gives same output pixel values.
I use datascope filter to inspect it.

ffplay input.file -vf datascope


More information about the ffmpeg-user mailing list