29 16, 20, 24, 0, 0, 0, 0, 0,
30 0, 0, 0, 0, 0, 0, 0, 0,
34 1, 2, 3, 4, 3, 4, 5, 3, 4, 5, 4, 5, 6, 4, 5, 4,
35 5, 6, 5, 5, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
60 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
65 int has_extension, extensions = 0;
70 if (
AV_RB32(buf) == 0xf8726fba) {
71 has_extension = buf[25] & 1;
73 extensions = buf[26] >> 4;
74 size += 2 + extensions * 2;
88 int ratebits, channel_arrangement, header_size;
94 if (header_size < 0 || gb->size_in_bits < header_size << 3) {
109 mh->header_size = header_size;
111 if (
mh->stream_type == 0xbb) {
121 mh->channel_arrangement=
122 channel_arrangement =
get_bits(gb, 5);
124 mh->channel_layout_mlp =
mlp_layout[channel_arrangement];
125 }
else if (
mh->stream_type == 0xba) {
126 mh->group1_bits = 24;
131 mh->group2_samplerate = 0;
135 mh->channel_modifier_thd_stream0 =
get_bits(gb, 2);
136 mh->channel_modifier_thd_stream1 =
get_bits(gb, 2);
138 mh->channel_arrangement=
139 channel_arrangement =
get_bits(gb, 5);
143 mh->channel_modifier_thd_stream2 =
get_bits(gb, 2);
145 channel_arrangement =
get_bits(gb, 13);
151 mh->access_unit_size = 40 << (ratebits & 7);
152 mh->access_unit_size_pow2 = 64 << (ratebits & 7);
158 mh->peak_bitrate = (
get_bits(gb, 15) *
mh->group1_samplerate + 8) >> 4;
163 mh->extended_substream_info =
get_bits(gb, 2);