[FFmpeg-devel] [PATCH] ffprobe: add option to control optional fields display

Gyan Doshi ffmpeg at gyani.pro
Tue May 4 19:32:53 EEST 2021



On 2021-05-04 21:12, Derek Buitenhuis wrote:
> On 01/05/2021 14:07, Gyan Doshi wrote:
>>   
>> + at item -show_optional_fields @var{value}
>> +Some writers viz. JSON and XML, omit the printing of fields with invalid or non-applicable values,
>> +while other writers always print them. This option enables one to control this behaviour.
>> +Valid values are @code{always}/@code{1}, @code{never}/@code{0} and @code{auto}/@code{-1}.
>> +Default is @var{auto}.
> Is the goal here to help badly written JSON or XML parsers?

No. It's to allow consumers of these writers to discover and access all 
fields if they choose to.

It's an obstacle I faced in a recent project.

Regards,
Gyan


More information about the ffmpeg-devel mailing list