From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTP id 96F9F44820 for ; Thu, 27 Oct 2022 18:27:01 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id B5AAB68BC15; Thu, 27 Oct 2022 21:26:58 +0300 (EEST) Received: from mail-oa1-f52.google.com (mail-oa1-f52.google.com [209.85.160.52]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id A99F068B554 for ; Thu, 27 Oct 2022 21:26:52 +0300 (EEST) Received: by mail-oa1-f52.google.com with SMTP id 586e51a60fabf-13c569e5ff5so2894784fac.6 for ; Thu, 27 Oct 2022 11:26:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:to :from:from:to:cc:subject:date:message-id:reply-to; bh=wXK0ITM7oCnXxT3K3ympAEgq0r+gR5JSsxccejbYp48=; b=J0Y1KDE5ELPWP+6QusjBg0Fk/8K01hRX7sGRRobMk2+sKEq70T2Wqro/2M3s+qByr2 uU3kV8QCXboz2XW1vZfXgx7WUrKhEhBBbqnHqMAepNi2fsgVzHZb7yczoAsUAOIzFoMy b0a+Dh7J2oXNdL3Ol1W/D0f5XrRmW0oHMaySHRNfxhle5CrTC+/TdoVCw/iqVNUsY+8W ANg5W0rXuSd6eULd8nQcRuEbfYMBtORx/2Aje4JKr9pcdrL7D6x2N4WHs0pDuIP1GcQc hmLF0L++stWSpHVMB2VjHLquqX4vKDX0cVGnb6L65i6gGnKGRW+HwFjpEvw1OUOMnQvT FZ3Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=wXK0ITM7oCnXxT3K3ympAEgq0r+gR5JSsxccejbYp48=; b=EGs1Spv1tMVZp0Kqopkzp2YSi/747Mgup+y+F7+p4mUu1zzUcORsb1tEabFmOHtp+u n3DBPyoBZMIPSwcLbjdMd/1hXL2l8Ss+4EjvSn+lmNLHEv77C+pqCHalHGCWpqnSw04S paPDvMikIIRLtRIwbRl13mi0jfWmlBpDxGNcOhtwGHvgJhLWy2SSduop75cOOs7hMxMU kCsztjFxIyRQE1g7BVF2DU+Md1HIrWi/Gc7Rm/ITeBsXTDay9bMx0feb2ngvaqcoQZit BI4E8WWiIDBZ82xas1shPzSeDAzE5T0vPuO6hEvpad5FxK9Xuf2z72FGtuOwp9RiR4vS Bumw== X-Gm-Message-State: ACrzQf05QpFz3FBfqaw5HUrMfJtxRBUnuQ4GeQf/1PXULz5gRHpQueeK HfuVe/c31OZ8qYIPSTk2rcqZG9u11sA= X-Google-Smtp-Source: AMsMyM5qBdeXS3FIILZt84e4kEIeaKWH1kj7rqd7NUqKv72Riw+YD88l9G1iFZokpRY2UPxFJazGuQ== X-Received: by 2002:a05:6870:ec93:b0:13b:8835:97e with SMTP id eo19-20020a056870ec9300b0013b8835097emr6417873oab.191.1666895210899; Thu, 27 Oct 2022 11:26:50 -0700 (PDT) Received: from localhost.localdomain ([191.97.187.183]) by smtp.gmail.com with ESMTPSA id j126-20020aca3c84000000b0035770fc6ca9sm696008oia.16.2022.10.27.11.26.49 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 27 Oct 2022 11:26:50 -0700 (PDT) From: James Almer To: ffmpeg-devel@ffmpeg.org Date: Thu, 27 Oct 2022 15:26:50 -0300 Message-Id: <20221027182652.46178-1-jamrial@gmail.com> X-Mailer: git-send-email 2.38.1 MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH 1/3] avcodec/aacdec: fix parsing streams with channel configuration 11 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: Set the correct amount of tags in tags_per_config[]. Also, there are no channels that correspond to a side element in this configuration, so reflect this in the list of known/supported channel layouts. Signed-off-by: James Almer --- libavcodec/aacdec_template.c | 4 +--- libavcodec/aacdectab.h | 6 +++--- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/libavcodec/aacdec_template.c b/libavcodec/aacdec_template.c index 4a9513d53e..c10bc743b6 100644 --- a/libavcodec/aacdec_template.c +++ b/libavcodec/aacdec_template.c @@ -731,9 +731,7 @@ static ChannelElement *get_che(AACContext *ac, int type, int elem_id) return ac->tag_che_map[TYPE_CPE][elem_id] = ac->che[TYPE_CPE][2]; } case 11: - if (ac->tags_mapped == 2 && - ac->oc[1].m4ac.chan_config == 11 && - type == TYPE_SCE) { + if (ac->tags_mapped == 3 && type == TYPE_SCE) { ac->tags_mapped++; return ac->tag_che_map[TYPE_SCE][elem_id] = ac->che[TYPE_SCE][1]; } diff --git a/libavcodec/aacdectab.h b/libavcodec/aacdectab.h index e38b93a534..327efbcde0 100644 --- a/libavcodec/aacdectab.h +++ b/libavcodec/aacdectab.h @@ -35,7 +35,7 @@ #include -static const int8_t tags_per_config[16] = { 0, 1, 1, 2, 3, 3, 4, 5, 0, 0, 0, 4, 5, 16, 5, 0 }; +static const int8_t tags_per_config[16] = { 0, 1, 1, 2, 3, 3, 4, 5, 0, 0, 0, 5, 5, 16, 5, 0 }; static const uint8_t aac_channel_layout_map[16][16][3] = { { { TYPE_SCE, 0, AAC_CHANNEL_FRONT }, }, @@ -81,7 +81,7 @@ static const uint64_t aac_channel_layout[] = { AV_CH_LAYOUT_5POINT0_BACK, AV_CH_LAYOUT_5POINT1_BACK, AV_CH_LAYOUT_7POINT1_WIDE_BACK, - AV_CH_LAYOUT_6POINT1, + AV_CH_LAYOUT_6POINT1_BACK, AV_CH_LAYOUT_7POINT1, AV_CH_LAYOUT_22POINT2, 0, @@ -97,7 +97,7 @@ static const AVChannelLayout aac_ch_layout[] = { AV_CHANNEL_LAYOUT_5POINT0_BACK, AV_CHANNEL_LAYOUT_5POINT1_BACK, AV_CHANNEL_LAYOUT_7POINT1_WIDE_BACK, - AV_CHANNEL_LAYOUT_6POINT1, + AV_CHANNEL_LAYOUT_6POINT1_BACK, AV_CHANNEL_LAYOUT_7POINT1, AV_CHANNEL_LAYOUT_22POINT2, { 0 }, -- 2.38.1 _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".