[FFmpeg-devel] 回复: [PATCH 2/2] avformat/mov: improve HEIF parsing

Wu Jianhua toqsxw at outlook.com
Sat Apr 13 14:04:57 EEST 2024


> 发件人: ffmpeg-devel <ffmpeg-devel-bounces at ffmpeg.org> 代表 James Almer <jamrial at gmail.com>
> 发送时间: 2024年1月9日 11:55
> 收件人: ffmpeg-devel at ffmpeg.org
> 主题: [FFmpeg-devel] [PATCH 2/2] avformat/mov: improve HEIF parsing
>
> Parse iinf boxes and its child infe boxes to get the actual codec used
> (AV1 for avif, HEVC for heic), and properly export extradata in a generic
> way.
>
> The avif tests reference files are updated as the extradata is now exported.
>
> Signed-off-by: James Almer <jamrial at gmail.com>
> ---
> libavformat/isom.h                            |   3 +-
> libavformat/mov.c                             | 157 ++++++++++--------
> .../fate/mov-avif-demux-still-image-1-item    |   2 +-
> .../mov-avif-demux-still-image-multiple-items |   2 +-
> 4 files changed, 95 insertions(+), 69 deletions(-)
>

> +    if (version != 2) {
> +        av_log(c->fc, AV_LOG_ERROR, "infe: version != 2 not supported.\n");
> +        return AVERROR_PATCHWELCOME;
> +    }
> +

Hi James,

With the change, some errors occurred and the current FFmpeg failed to decode a lot of videos that can be decoded by older FFmpeg.
[mov,mp4,m4a,3gp,3g2,mj2 @ 000001e6e79aac80] st: 0 edit list: 1 Missing key frame while searching for timestamp: 1000
[mov,mp4,m4a,3gp,3g2,mj2 @ 000001e6e79aac80] st: 0 edit list 1 Cannot find an index entry before timestamp: 1000.
[mov,mp4,m4a,3gp,3g2,mj2 @ 000001e6e79aac80] infe: version < 2 not supported
[mov,mp4,m4a,3gp,3g2,mj2 @ 000001e6e79aac80] error reading header

I'm not familiar with the mov. Is it possible to treat this error as a warning and skip it when the version < 2?

Thanks,
Jianhua



More information about the ffmpeg-devel mailing list