[FFmpeg-user] HD > SD Down-Convert Prores Color

Kevin Wheatley kevin.j.wheatley at gmail.com
Fri May 15 10:39:00 CEST 2015


On Thu, May 14, 2015 at 4:49 PM, Kevin Wells <kevwells at hotmail.co.uk> wrote:
> Hi Kevin, what would be your suggestion for a possible work-around?

you can control the conversion ffmpeg adds automatically by using an
explicit  "-vf scale=out_color_matrix=bt709" when going from RGB to
YCbCr substitute what you need for the bt709 if you need something
else. Then when decoding from YCbCr you can specify in_color_matrix
(look for  "auto-insert" when adding --loglevel verbose to the ffmpeg
command line to see this).

They key here is to realise that ffmpeg 'auto-inserts' a scaler to
perform RGB<->YCbCr and the setup of that scalar is sometimes not in
agrement with the input/output codec/format as it defaults to bt470bg
(I guess for historical backwards compatibility) and the code doesn't
have an obvious way for the formats/codecs to communicate to the
scalar what settings to use automatically.

Historically you can search on the archives and find there are lots of
people suggesting to use -colormatrix to do additional matrixing to
fix this, but the cleaner option in the current ffmpeg code is to
directly say what you want to happen in the scaler.

For decoding there is a way for the matrix to be passed in, but this
doesn't always work - the movie file might not be tagged with the
settings used to encode the movie for instance.

Kevin


More information about the ffmpeg-user mailing list