dump: print the original coded dimensions when available
authorVittorio Giovara <vittorio.giovara@gmail.com>
Fri, 26 Sep 2014 14:24:07 +0000 (15:24 +0100)
committerVittorio Giovara <vittorio.giovara@gmail.com>
Wed, 8 Oct 2014 17:17:49 +0000 (18:17 +0100)
libavcodec/utils.c

index 9e8f541..89f249f 100644 (file)
@@ -1950,6 +1950,12 @@ void avcodec_string(char *buf, int buf_size, AVCodecContext *enc, int encode)
                      "%dx%d",
                      enc->width, enc->height);
 
+            if (av_log_get_level() >= AV_LOG_VERBOSE &&
+                (enc->width != enc->coded_width ||
+                 enc->height != enc->coded_height))
+                snprintf(buf + strlen(buf), buf_size - strlen(buf),
+                         " (%dx%d)", enc->coded_width, enc->coded_height);
+
             if (enc->sample_aspect_ratio.num) {
                 av_reduce(&display_aspect_ratio.num, &display_aspect_ratio.den,
                           enc->width * enc->sample_aspect_ratio.num,