[FFmpeg-devel] [PATCH] vf_colorspace: Add support for film primaries

Ronald S. Bultje rsbultje at gmail.com
Tue Nov 1 23:49:01 EET 2016


Hi,

On Mon, Oct 31, 2016 at 2:49 PM, Ronald S. Bultje <rsbultje at gmail.com>
wrote:

> Hi,
>
> On Mon, Oct 31, 2016 at 2:43 PM, Vittorio Giovara <
> vittorio.giovara at gmail.com> wrote:
>
>> Signed-off-by: Vittorio Giovara <vittorio.giovara at gmail.com>
>> ---
>> This is the last easy picking, the remaining trc/prm require more
>> convoluted
>> changes to the filter that will need more discussion.
>> Please CC.
>> Vittorio
>>
>>  libavfilter/vf_colorspace.c | 2 ++
>>  1 file changed, 2 insertions(+)
>>
>> diff --git a/libavfilter/vf_colorspace.c b/libavfilter/vf_colorspace.c
>> index 4265aa1..997c594 100644
>> --- a/libavfilter/vf_colorspace.c
>> +++ b/libavfilter/vf_colorspace.c
>> @@ -278,6 +278,7 @@ static const struct ColorPrimaries
>> color_primaries[AVCOL_PRI_NB] = {
>>      [AVCOL_PRI_BT470BG]   = { WP_D65, 0.640, 0.330, 0.290, 0.600, 0.150,
>> 0.060,},
>>      [AVCOL_PRI_SMPTE170M] = { WP_D65, 0.630, 0.340, 0.310, 0.595, 0.155,
>> 0.070 },
>>      [AVCOL_PRI_SMPTE240M] = { WP_D65, 0.630, 0.340, 0.310, 0.595, 0.155,
>> 0.070 },
>> +    [AVCOL_PRI_FILM]      = { WP_C,   0.681, 0.319, 0.243, 0.692, 0.145,
>> 0.049 },
>>      [AVCOL_PRI_SMPTE431]  = { WP_DCI, 0.680, 0.320, 0.265, 0.690, 0.150,
>> 0.060 },
>>      [AVCOL_PRI_SMPTE432]  = { WP_D65, 0.680, 0.320, 0.265, 0.690, 0.150,
>> 0.060 },
>>      [AVCOL_PRI_BT2020]    = { WP_D65, 0.708, 0.292, 0.170, 0.797, 0.131,
>> 0.046 },
>> @@ -1084,6 +1085,7 @@ static const AVOption colorspace_options[] = {
>>      ENUM("bt470bg",      AVCOL_PRI_BT470BG,    "prm"),
>>      ENUM("smpte170m",    AVCOL_PRI_SMPTE170M,  "prm"),
>>      ENUM("smpte240m",    AVCOL_PRI_SMPTE240M,  "prm"),
>> +    ENUM("film",         AVCOL_PRI_FILM,       "prm"),
>>      ENUM("smpte431",     AVCOL_PRI_SMPTE431,   "prm"),
>>      ENUM("smpte432",     AVCOL_PRI_SMPTE432,   "prm"),
>>      ENUM("bt2020",       AVCOL_PRI_BT2020,     "prm"),
>> --
>> 2.10.0
>
>
> I can't believe you found content that uses this :D
>
> lgtm.
>

Pushed.

Ronald


More information about the ffmpeg-devel mailing list