[FFmpeg-devel] [PATCH 1/3] lavc/mediacodecdec: remove first output buffer timing debug log

Matthieu Bouron matthieu.bouron at gmail.com
Thu Oct 6 15:31:55 EEST 2016


From: Matthieu Bouron <matthieu.bouron at stupeflix.com>

---
 libavcodec/mediacodecdec.c | 8 --------
 libavcodec/mediacodecdec.h | 3 ---
 2 files changed, 11 deletions(-)

diff --git a/libavcodec/mediacodecdec.c b/libavcodec/mediacodecdec.c
index 0faa4cf..2ab173b 100644
--- a/libavcodec/mediacodecdec.c
+++ b/libavcodec/mediacodecdec.c
@@ -439,9 +439,6 @@ static int mediacodec_dec_flush_codec(AVCodecContext *avctx, MediaCodecDecContex
         return AVERROR_EXTERNAL;
     }
 
-    s->first_buffer = 0;
-    s->first_buffer_at = av_gettime();
-
     return 0;
 }
 
@@ -458,7 +455,6 @@ int ff_mediacodec_dec_init(AVCodecContext *avctx, MediaCodecDecContext *s,
         AV_PIX_FMT_NONE,
     };
 
-    s->first_buffer_at = av_gettime();
     s->refcount = 1;
 
     pix_fmt = ff_get_format(avctx, pix_fmts);
@@ -636,10 +632,6 @@ int ff_mediacodec_dec_decode(AVCodecContext *avctx, MediaCodecDecContext *s,
     if (index >= 0) {
         int ret;
 
-        if (!s->first_buffer++) {
-            av_log(avctx, AV_LOG_DEBUG, "Got first buffer after %fms\n", (av_gettime() - s->first_buffer_at) / 1000);
-        }
-
         av_log(avctx, AV_LOG_DEBUG, "Got output buffer %zd"
                 " offset=%" PRIi32 " size=%" PRIi32 " ts=%" PRIi64
                 " flags=%" PRIu32 "\n", index, info.offset, info.size,
diff --git a/libavcodec/mediacodecdec.h b/libavcodec/mediacodecdec.h
index 8613352..52c8bf1 100644
--- a/libavcodec/mediacodecdec.h
+++ b/libavcodec/mediacodecdec.h
@@ -61,9 +61,6 @@ typedef struct MediaCodecDecContext {
 
     uint64_t dequeued_buffer_nb;
 
-    int first_buffer;
-    double first_buffer_at;
-
 } MediaCodecDecContext;
 
 int ff_mediacodec_dec_init(AVCodecContext *avctx,
-- 
2.10.0



More information about the ffmpeg-devel mailing list