[FFmpeg-devel] [PATCHv2] vf_colorspace: Allow overriding input color properties

Ronald S. Bultje rsbultje at gmail.com
Tue Aug 30 18:45:16 EEST 2016


Hi,

On Tue, Aug 30, 2016 at 10:00 AM, Vittorio Giovara <
vittorio.giovara at gmail.com> wrote:

> On Tue, Aug 30, 2016 at 4:13 AM, Paul B Mahol <onemda at gmail.com> wrote:
> >
> >
> > On Mon, Aug 29, 2016 at 5:53 PM, Ronald S. Bultje <rsbultje at gmail.com>
> > wrote:
> >>
> >> Hi,
> >>
> >> On Mon, Aug 29, 2016 at 11:23 AM, Vittorio Giovara <
> >> vittorio.giovara at gmail.com> wrote:
> >>
> >> > The filter needs input frames with color properties filled out by
> >> > the decoder. Since this is not always possible, add input options to
> >> > the filter so that user may override color space, color primaries,
> >> > transfer characteristics, and color range, as well as a generic option
> >> > to set all properties at once.
> >> >
> >> > Signed-off-by: Vittorio Giovara <vittorio.giovara at gmail.com>
> >> > ---
> >> > * added iall option
> >> > * updated filter documentation
> >> >
> >> > Please CC.
> >> > Vittorio
> >> >
> >> >  doc/filters.texi            | 20 ++++++++++++++++++++
> >> >  libavfilter/vf_colorspace.c | 39
> >> > ++++++++++++++++++++++++++++++++++-----
> >> >  2 files changed, 54 insertions(+), 5 deletions(-)
> >>
> >>
> >> lgtm.
> >>
> >> (I wonder if the error message - if the input AVFrame has no
> >> trc/rng/csp/prm - should be changed to reflect that you can override
> them
> >> using the added properties? This isn't a big deal but maybe someone
> feels
> >> that's important.)
> >
> >
> > Still breaks backward compatibility.
>
> I fail to see how, can you provide more details?


You can use ordered, unnamed properties to configure filters (-vf
colorspace=bt709:bt709:jpeg is identical to -vf
colorspace=all=bt709:space=bt709:range=jpeg; this probably shows how range
should've been before space to be especially useful, but whatever), and
that breaks after this patch because you changed the ordering.

Ronald


More information about the ffmpeg-devel mailing list