avformat/iamf_parse: ensure each layout in an scalable channel representation has an increasing number of channels
Fixes issue #21013 Signed-off-by: James Almer <jamrial@gmail.com>
This commit is contained in:
parent
3bcf2be06c
commit
554ae5ada9
1 changed files with 3 additions and 0 deletions
|
|
@ -406,6 +406,9 @@ static int scalable_channel_layout_config(void *s, AVIOContext *pb,
|
|||
.nb_channels = substream_count +
|
||||
coupled_substream_count };
|
||||
|
||||
if (i && ch_layout.nb_channels <= audio_element->element->layers[i-1]->ch_layout.nb_channels)
|
||||
return AVERROR_INVALIDDATA;
|
||||
|
||||
for (int j = 0; j < substream_count; j++) {
|
||||
IAMFSubStream *substream = &audio_element->substreams[k++];
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue