PR #26048 opened by Baptiste Coudurier (bcoudurier) URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/26048 Patch URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/26048.patch
A single-stream MP4 has no alternative track to select. Use the default alternate group of zero in this case, as in Apple-generated single-track MP4 files. Preserve the existing grouping of multi-stream files. >From a52b6dfcbb92324019673dc4726d6cae947d2ec7 Mon Sep 17 00:00:00 2001 From: Baptiste Coudurier <[email protected]> Date: Fri, 13 Nov 2026 21:13:52 -0800 Subject: [PATCH] avformat/movenc: leave standalone MP4 tracks outside an alternate group A single-stream MP4 has no alternative track to select. Use the default alternate group of zero in this case, as in Apple-generated single-track MP4 files. Preserve the existing grouping of multi-stream files. --- libavformat/movenc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/movenc.c b/libavformat/movenc.c index c3fa66d816c..1e3594a3056 100644 --- a/libavformat/movenc.c +++ b/libavformat/movenc.c @@ -4158,7 +4158,7 @@ static int mov_write_tkhd_tag(AVIOContext *pb, MOVMuxContext *mov, const AVPacketSideData *sd; if (mov->per_stream_grouping) group = st->index; - else + else if (mov->mode != MODE_MP4 || mov->nb_streams > 1) group = st->codecpar->codec_type; sd = av_packet_side_data_get(st->codecpar->coded_side_data, -- 2.54.0 _______________________________________________ ffmpeg-devel mailing list -- [email protected] To unsubscribe send an email to [email protected]
