This is an automated email from the git hooks/post-receive script.

Git pushed a commit to branch master
in repository ffmpeg.

commit f35acb72ac567821d52da6d53a3e06a3c97855f3
Author:     James Almer <[email protected]>
AuthorDate: Fri Aug 21 11:16:32 2026 -0300
Commit:     James Almer <[email protected]>
CommitDate: Sun Aug 23 13:35:29 2026 -0300

    avcodec/aacenc: add support for ambisonic layouts
    
    AAC can't signal such layouts, so this is merely a hack to allow such
    streams to be passed to the encoder instead of having to define layouts
    using arbitrary speaker positions for the sake of having one with the
    required amount of channels.
    
    Signed-off-by: James Almer <[email protected]>
---
 libavcodec/aacenc.c | 24 ++++++++++++++++++++++++
 1 file changed, 24 insertions(+)

diff --git a/libavcodec/aacenc.c b/libavcodec/aacenc.c
index 7e263a64ed..df54149631 100644
--- a/libavcodec/aacenc.c
+++ b/libavcodec/aacenc.c
@@ -404,6 +404,30 @@ static const AACPCEInfo aac_pce_configs[] = {
         .config_map = { 9, TYPE_SCE, TYPE_CPE, TYPE_CPE, TYPE_CPE, TYPE_CPE, 
TYPE_LFE, TYPE_CPE, TYPE_CPE, TYPE_CPE },
         .reorder_map = { 2, 6, 7, 0, 1, 8, 9, 4, 5, 3, 10, 11, 14, 15, 12, 13 
},
     },
+    {
+        .layout = AV_CHANNEL_LAYOUT_AMBISONIC_FIRST_ORDER,
+        .num_ele = { 1, 0, 1, 0 },
+        .pairing = { { 1 }, { 0 }, { 1 }, },
+        .index = { { 0 }, { 0 }, { 1 } },
+        .config_map = { 2, TYPE_CPE, TYPE_CPE },
+        .reorder_map = { 0, 1, 2, 3 },
+    },
+    {
+        .layout = { .order = AV_CHANNEL_ORDER_AMBISONIC, .nb_channels = 9 },
+        .num_ele = { 3, 0, 2, 0 },
+        .pairing = { { 0, 1, 1 }, { 0 }, { 1, 1 }, },
+        .index = { { 0, 0, 1 }, { 0 }, { 2, 3 }, },
+        .config_map = { 5, TYPE_SCE, TYPE_CPE, TYPE_CPE, TYPE_CPE, TYPE_CPE },
+        .reorder_map = { 2, 5, 6, 0, 1, 7, 8, 3, 4 },
+    },
+    {
+        .layout = { .order = AV_CHANNEL_ORDER_AMBISONIC, .nb_channels = 16 },
+        .num_ele = { 4, 0, 4, 0 },
+        .pairing = { { 1, 1, 1, 1 }, { 0 }, { 1, 1, 1, 1 }, },
+        .index = { { 0, 1, 2, 3 }, { 0 }, { 4, 5, 6, 7 }, },
+        .config_map = { 8, TYPE_CPE, TYPE_CPE, TYPE_CPE, TYPE_CPE, TYPE_CPE, 
TYPE_CPE, TYPE_CPE, TYPE_CPE },
+        .reorder_map = { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15 
},
+    },
 };
 
 static void put_pce(PutBitContext *pb, AVCodecContext *avctx)

-- 
To stop receiving notification emails like this one, please contact
[email protected].
_______________________________________________
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to