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

Git pushed a commit to branch master
in repository ffmpeg.

commit 2e6af104816dec3f847800adc7bee723d9b509f7
Author:     James Almer <[email protected]>
AuthorDate: Thu Apr 23 10:42:58 2026 -0300
Commit:     James Almer <[email protected]>
CommitDate: Wed Apr 29 14:00:03 2026 +0000

    avformat/dashdec: copy stream groups from input representations
    
    Signed-off-by: James Almer <[email protected]>
---
 libavformat/dashdec.c | 39 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 39 insertions(+)

diff --git a/libavformat/dashdec.c b/libavformat/dashdec.c
index 7aa6121695..83688d0ae0 100644
--- a/libavformat/dashdec.c
+++ b/libavformat/dashdec.c
@@ -21,6 +21,7 @@
  */
 #include <libxml/parser.h>
 #include <time.h>
+#include "libavutil/avassert.h"
 #include "libavutil/bprint.h"
 #include "libavutil/mem.h"
 #include "libavutil/opt.h"
@@ -2021,6 +2022,44 @@ static int open_demux_for_component(AVFormatContext *s, 
struct representation *p
         st->disposition = ist->disposition;
     }
 
+    for (i = 0; i < pls->ctx->nb_stream_groups; i++) {
+        AVStreamGroup *istg = pls->ctx->stream_groups[i];
+        AVStreamGroup *stg;
+
+        if (istg->type != AV_STREAM_GROUP_PARAMS_LCEVC)
+            continue;
+
+        stg = avformat_stream_group_create(s, istg->type, NULL);
+        if (!stg)
+            return AVERROR(ENOMEM);
+
+        stg->id = s->nb_stream_groups;
+
+        for (int j = 0; j < istg->nb_streams; j++) {
+            AVStream *ist = istg->streams[j];
+            AVStream *st = s->streams[ist->index + pls->stream_index];
+            ret = avformat_stream_group_add_stream(stg, st);
+            if (ret < 0)
+                return ret;
+        }
+
+        switch (stg->type) {
+        case AV_STREAM_GROUP_PARAMS_LCEVC: {
+            AVStreamGroupLCEVC *ilcevc = istg->params.lcevc;
+            AVStreamGroupLCEVC *lcevc = stg->params.lcevc;
+            ret = av_opt_copy(lcevc, ilcevc);
+            if (ret < 0)
+                return ret;
+            break;
+        }
+        default:
+            av_unreachable("Unsupported Stream Group type should have been 
checked above");
+        }
+
+        // copy disposition
+        stg->disposition = istg->disposition;
+    }
+
     return 0;
 }
 

_______________________________________________
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to