mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 20:21:24 +00:00
qtdemux: fix aac channel override based on codec data for 7.1 case
This commit is contained in:
parent
845a3d6c3d
commit
64753bdbe8
1 changed files with 4 additions and 1 deletions
|
@ -7499,9 +7499,12 @@ gst_qtdemux_handle_esds (GstQTDemux * qtdemux, QtDemuxStream * stream,
|
|||
if (data_ptr && data_len == 2) {
|
||||
guint channels, rateindex, rate;
|
||||
|
||||
/* FIXME: add gst_codec_utils_aac_get_{channels|sample_rate}()? */
|
||||
channels = (data_ptr[1] & 0x7f) >> 3;
|
||||
if (channels <= 7) {
|
||||
if (channels > 0 && channels < 7) {
|
||||
stream->n_channels = channels;
|
||||
} else if (channels == 7) {
|
||||
stream->n_channels = 8;
|
||||
}
|
||||
|
||||
rateindex = ((data_ptr[0] & 0x7) << 1) | ((data_ptr[1] & 0x80) >> 7);
|
||||
|
|
Loading…
Reference in a new issue