[FFmpeg-devel] [PATCH] avformat/movenc: Always look up mov tag for AV1.

James Almer jamrial at gmail.com
Tue Aug 14 02:02:17 EEST 2018


On 8/13/2018 7:58 PM, James Almer wrote:
> On 8/13/2018 7:47 PM, Carl Eugen Hoyos wrote:
>> 2018-08-14 0:36 GMT+02:00, Thomas Daede <bztdlinux at gmail.com>:
>>> On 08/13/2018 03:30 PM, Carl Eugen Hoyos wrote:
>>>> Why isn't av1 added like the existing codecs?
>>>
>>> That would generate invalid AV1 files if -strict -1 or -2 specified
>>
>> That is the idea of -1 and -2.
>>
>>> (and currently AV1 mov writing is behind -2).
>>
>> Is the specification still unfinished?
> 
> Yes.
> 
>> Then what is the exact purpose of this patch?
> 
> The issue at hand is that when remuxing from ivf, the propagated codec
> tag AV01 is written as is instead of the correct av01 (as listed in
> ff_codec_movvideo_tags and codec_mp4_tags) because a case insensitive
> check takes place in either ffmpeg.c or libavformat generic code (i
> don't recall exactly where), which of course assumes av01 == AV01.
> The latter is only correct for ivf, not mp4.
> 
> If this patch adds the AV1 codec id inside the "s->strict_std_compliance
>> = FF_COMPLIANCE_NORMAL" check as you suggest, and a muxing process is
> done with -strict experimental, then the wrong codec_tag will be written.
> 
> An alternative would be to change the aforementioned case insensitive
> check into a case sensitive one, but that could break some other
> scenarios as i presume it was made that way for a reason.

If you're curious why this doesn't happen with VP9, another format
supported by both ivf and mp4, it's because ivf is VP90 and mp4 is vp09.


More information about the ffmpeg-devel mailing list