[FFmpeg-cvslog] avdevice/lavfi: do not rescale AV_NOPTS_VALUE in lavfi_read_packet()

Michael Niedermayer git at videolan.org
Thu Aug 20 14:53:39 CEST 2015


ffmpeg | branch: release/2.4 | Michael Niedermayer <michaelni at gmx.at> | Wed Jun 10 00:47:43 2015 +0200| [402f832984637d75284a28f5cd1e8d46b10eed9b] | committer: Michael Niedermayer

avdevice/lavfi: do not rescale AV_NOPTS_VALUE in lavfi_read_packet()

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
(cherry picked from commit 913685f55208efd78bfc34d82b261bd449e69774)

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=402f832984637d75284a28f5cd1e8d46b10eed9b
---

 libavdevice/lavfi.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavdevice/lavfi.c b/libavdevice/lavfi.c
index 1398ece..f6c92bc 100644
--- a/libavdevice/lavfi.c
+++ b/libavdevice/lavfi.c
@@ -339,7 +339,7 @@ static int lavfi_read_packet(AVFormatContext *avctx, AVPacket *pkt)
             continue;
         } else if (ret < 0)
             return ret;
-        d = av_rescale_q(frame->pts, tb, AV_TIME_BASE_Q);
+        d = av_rescale_q_rnd(frame->pts, tb, AV_TIME_BASE_Q, AV_ROUND_NEAR_INF|AV_ROUND_PASS_MINMAX);
         av_dlog(avctx, "sink_idx:%d time:%f\n", i, d);
         av_frame_unref(frame);
 



More information about the ffmpeg-cvslog mailing list