[FFmpeg-devel] [PATCH] vp9_parser: don't overwrite cached timestamps with nopts.

Ronald S. Bultje rsbultje at gmail.com
Wed Oct 28 17:21:05 CET 2015


---
 libavcodec/vp9_parser.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/vp9_parser.c b/libavcodec/vp9_parser.c
index 0437097..6713850 100644
--- a/libavcodec/vp9_parser.c
+++ b/libavcodec/vp9_parser.c
@@ -64,7 +64,7 @@ static int parse_frame(AVCodecParserContext *ctx, const uint8_t *buf, int size)
         if (ctx->pts == AV_NOPTS_VALUE)
             ctx->pts = s->pts;
         s->pts = AV_NOPTS_VALUE;
-    } else {
+    } else if (ctx->pts != AV_NOPTS_VALUE) {
         s->pts = ctx->pts;
         ctx->pts = AV_NOPTS_VALUE;
     }
-- 
2.1.2



More information about the ffmpeg-devel mailing list