[FFmpeg-devel] [PATCH 1/2] Add additional color spaces and transfer characteristics defined in H.264

David Conrad lessen42
Tue Jan 5 07:00:44 CET 2010


On Jan 4, 2010, at 8:36 PM, Michael Niedermayer wrote:

> On Mon, Jan 04, 2010 at 08:00:21PM -0500, David Conrad wrote:
>> On Jan 4, 2010, at 7:48 PM, Michael Niedermayer wrote:
>> 
>>> On Mon, Jan 04, 2010 at 07:12:09PM -0500, David Conrad wrote:
>>>> ---
>>>> libavcodec/avcodec.h |    8 ++++++++
>>>> 1 files changed, 8 insertions(+), 0 deletions(-)
>>>> 
>>>> diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h
>>>> index c982a64..20d07a0 100644
>>>> --- a/libavcodec/avcodec.h
>>>> +++ b/libavcodec/avcodec.h
>>>> @@ -475,6 +475,13 @@ enum AVColorTransferCharacteristic{
>>>>    AVCOL_TRC_UNSPECIFIED=2,
>>>>    AVCOL_TRC_GAMMA22    =4, ///< also ITU-R BT470M / ITU-R BT1700 625 PAL & SECAM
>>>>    AVCOL_TRC_GAMMA28    =5, ///< also ITU-R BT470BG
>>> 
>>>> +    AVCOL_TRC_SMPTE170M  =6, ///< equivalent to 1
>>> 
>>> if its equivalent to 1 adding it has little sense
>> 
>> It's the same sort of thing as AVCOL_PRI_SMPTE170M vs. AVCOL_PRI_SMPTE240M but it can be ignored.
> 
> hmm, i see we already have duplicates, in that case feel free to add
> this one
> 
> 
>> 
>>> +    AVCOL_TRC_SMPTE240M  =7,
>>>> +    AVCOL_TRC_LINEAR     =8,
>>>> +    AVCOL_TRC_LOG100     =9, ///< logarithmic, 100:1 range
>>>> +    AVCOL_TRC_LOG316     =10,///< logarithmic, 316.22777:1 range
>>>> +    AVCOL_TRC_IEC61966   =11,///< IEC 61966-2-4
>>>> +    AVCOL_TRC_BT1361_EXT =12,///< ITU-R BT1361 extended gamut
>>>>    AVCOL_TRC_NB           , ///< Not part of ABI
>>>> };
>>>> 
>>>> @@ -486,6 +493,7 @@ enum AVColorSpace{
>>>>    AVCOL_SPC_BT470BG    =5, ///< also ITU-R BT601-6 625 / ITU-R BT1358 625 / ITU-R BT1700 625 PAL & SECAM / IEC 61966-2-4 xvYCC601
>>>>    AVCOL_SPC_SMPTE170M  =6, ///< also ITU-R BT601-6 525 / ITU-R BT1358 525 / ITU-R BT1700 NTSC / functionally identical to above
>>>>    AVCOL_SPC_SMPTE240M  =7,
>>>> +    AVCOL_SPC_YCgCo      =8, ///< reversable YUV as defined in H.264
>>>>    AVCOL_SPC_NB           , ///< Not part of ABI
>>>> };
>>> 
>>> are these used by anyone in practice?
>>> if no, then i see no sense in adding them
>> 
>> YCgCo is iirc the only colorspace in JPEG-XR. Everything else, probably not.
> 
> so new question
> is JPEG-XR used by anyone in practice?

Not as far as I can tell, I really had to hunt to find any samples when I briefly considered writing a decoder.



More information about the ffmpeg-devel mailing list