PR #23457 opened by James Almer (jamrial)
URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/23457
Patch URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/23457.patch


>From 591d2fc1330a07decb30ec4aedf1d86817255f58 Mon Sep 17 00:00:00 2001
From: James Almer <[email protected]>
Date: Fri, 12 Jun 2026 00:20:11 -0300
Subject: [PATCH] avformat/dump: support printing Dolby Vision stream group
 information

Signed-off-by: James Almer <[email protected]>
---
 libavformat/dump.c | 16 +++++++++-------
 1 file changed, 9 insertions(+), 7 deletions(-)

diff --git a/libavformat/dump.c b/libavformat/dump.c
index 9e0a4adad2..48f96611b8 100644
--- a/libavformat/dump.c
+++ b/libavformat/dump.c
@@ -810,17 +810,19 @@ static void dump_stream_group(const AVFormatContext *ic, 
uint8_t *printed,
         }
         break;
     }
+    case AV_STREAM_GROUP_PARAMS_DOLBY_VISION:
     case AV_STREAM_GROUP_PARAMS_LCEVC: {
-        const AVStreamGroupLayeredVideo *lcevc = stg->params.layered_video;
+        const AVStreamGroupLayeredVideo *layered_video = 
stg->params.layered_video;
         AVCodecContext *avctx = avcodec_alloc_context3(NULL);
         const char *ptr = NULL;
-        av_log(NULL, AV_LOG_INFO, " LCEVC:");
+        av_log(NULL, AV_LOG_INFO, " %s:", stg->type == 
AV_STREAM_GROUP_PARAMS_DOLBY_VISION ?
+                                          "Dolby Vision" : "LCEVC");
         if (avctx && stg->nb_streams == 2 &&
-            !avcodec_parameters_to_context(avctx, 
stg->streams[!lcevc->el_index]->codecpar)) {
-            avctx->width  = lcevc->width;
-            avctx->height = lcevc->height;
-            avctx->coded_width  = lcevc->width;
-            avctx->coded_height = lcevc->height;
+            !avcodec_parameters_to_context(avctx, 
stg->streams[!layered_video->el_index]->codecpar)) {
+            avctx->width  = layered_video->width;
+            avctx->height = layered_video->height;
+            avctx->coded_width  = layered_video->width;
+            avctx->coded_height = layered_video->height;
             if (ic->dump_separator)
                 av_opt_set(avctx, "dump_separator", ic->dump_separator, 0);
             buf[0] = 0;
-- 
2.52.0

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

Reply via email to