ffprobe: Print AVContentLightMetadata side data contents
authorVittorio Giovara <vittorio.giovara@gmail.com>
Wed, 31 May 2017 15:55:11 +0000 (11:55 -0400)
committerVittorio Giovara <vittorio.giovara@gmail.com>
Thu, 1 Jun 2017 19:07:16 +0000 (15:07 -0400)
ffprobe.c

index f6d0264..b3464aa 100644 (file)
--- a/ffprobe.c
+++ b/ffprobe.c
@@ -1913,6 +1913,10 @@ static void print_pkt_side_data(WriterContext *w,
                 print_q("min_luminance", metadata->min_luminance, '/');
                 print_q("max_luminance", metadata->max_luminance, '/');
             }
+        } else if (sd->type == AV_PKT_DATA_CONTENT_LIGHT_LEVEL) {
+            AVContentLightMetadata *metadata = (AVContentLightMetadata *)sd->data;
+            print_int("max_content", metadata->MaxCLL);
+            print_int("max_average", metadata->MaxFALL);
         }
         writer_print_section_footer(w);
     }
@@ -2155,6 +2159,10 @@ static void show_frame(WriterContext *w, AVFrame *frame, AVStream *stream,
                     print_q("min_luminance", metadata->min_luminance, '/');
                     print_q("max_luminance", metadata->max_luminance, '/');
                 }
+            } else if (sd->type == AV_FRAME_DATA_CONTENT_LIGHT_LEVEL) {
+                AVContentLightMetadata *metadata = (AVContentLightMetadata *)sd->data;
+                print_int("max_content", metadata->MaxCLL);
+                print_int("max_average", metadata->MaxFALL);
             }
             writer_print_section_footer(w);
         }