This is an automated email from the git hooks/post-receive script. Git pushed a commit to branch master in repository ffmpeg.
commit a0fc454871c116d5bd1bbec5138dfe3ffcb1f11d Author: James Almer <[email protected]> AuthorDate: Sat Dec 27 19:11:07 2025 -0300 Commit: James Almer <[email protected]> CommitDate: Mon Dec 29 12:00:01 2025 -0300 avformat/iamf_writer: check that stream count is consistent for ambisonic Audio Elements Signed-off-by: James Almer <[email protected]> --- libavformat/iamf_writer.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/libavformat/iamf_writer.c b/libavformat/iamf_writer.c index 44a32f0ce0..fc8e492c66 100644 --- a/libavformat/iamf_writer.c +++ b/libavformat/iamf_writer.c @@ -659,8 +659,12 @@ static int ambisonics_config(const IAMFAudioElement *audio_element, AVIOContext *dyn_bc) { const AVIAMFAudioElement *element = audio_element->celement; + const IAMFLayer *ilayer = &audio_element->layers[0]; const AVIAMFLayer *layer = element->layers[0]; + if (audio_element->nb_substreams != ilayer->substream_count) + return AVERROR(EINVAL); + ffio_write_leb(dyn_bc, 0); // ambisonics_mode avio_w8(dyn_bc, layer->ch_layout.nb_channels); // output_channel_count avio_w8(dyn_bc, audio_element->nb_substreams); // substream_count _______________________________________________ ffmpeg-cvslog mailing list -- [email protected] To unsubscribe send an email to [email protected]
