[FFmpeg-devel] [PATCH] libdav1d: Add support for reading hdr10 metadata

James Almer jamrial at gmail.com
Wed Mar 6 15:26:23 EET 2019


On 3/6/2019 5:07 AM, Carl Eugen Hoyos wrote:
> 2019-03-05 19:26 GMT+01:00, James Almer <jamrial at gmail.com>:
>> On 3/5/2019 3:19 PM, Vittorio Giovara wrote:
> 
>>> +    if (p->mastering_display) {
>>> +        AVMasteringDisplayMetadata *mastering =
>>> av_mastering_display_metadata_create_side_data(frame);
>>> +        if (!mastering)
>>> +            return AVERROR(ENOMEM);
>>> +
>>> +        for (i = 0; i < 3; i++) {
>>
>> for (int i = 0,...)
> 
> Being allowed to use doesn't mean it has to be used, no?
> There also is a smaller scope...
> 
> Carl Eugen

There's no smaller scope than directly declaring it in the for() line.
But he can add it right below the AVMasteringDisplayMetadata declaration
if that's preferred. If just don't see why adding an extra line to the
file would be preferred in this specific case to begin with.


More information about the ffmpeg-devel mailing list