summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2016-03-20 07:51:11 +0100
committerAnton Khirnov <anton@khirnov.net>2016-06-21 19:54:42 +0200
commitbeb62dac629603eb074a44c44389c230b5caac7c (patch)
tree19710471110c23126b14708b8ee0d998eeea9163
parent32c8359093d1ff4f45ed19518b449b3ac3769d27 (diff)
Use AVFrame.pts instead of deprecated pkt_pts.
-rw-r--r--avconv.c2
-rw-r--r--avplay.c4
-rw-r--r--libavfilter/vsrc_movie.c2
3 files changed, 3 insertions, 5 deletions
diff --git a/avconv.c b/avconv.c
index 385eb2c16b..bd84d9b965 100644
--- a/avconv.c
+++ b/avconv.c
@@ -1279,7 +1279,7 @@ static int decode_video(InputStream *ist, AVPacket *pkt, int *got_output)
}
ist->hwaccel_retrieved_pix_fmt = decoded_frame->format;
- decoded_frame->pts = guess_correct_pts(&ist->pts_ctx, decoded_frame->pkt_pts,
+ decoded_frame->pts = guess_correct_pts(&ist->pts_ctx, decoded_frame->pts,
decoded_frame->pkt_dts);
if (ist->st->sample_aspect_ratio.num)
diff --git a/avplay.c b/avplay.c
index 0e128af553..47701320bc 100644
--- a/avplay.c
+++ b/avplay.c
@@ -1406,9 +1406,9 @@ static int get_video_frame(PlayerState *is, AVFrame *frame, int64_t *pts, AVPack
if (got_picture) {
if (decoder_reorder_pts == -1) {
- *pts = guess_correct_pts(&is->pts_ctx, frame->pkt_pts, frame->pkt_dts);
+ *pts = guess_correct_pts(&is->pts_ctx, frame->pts, frame->pkt_dts);
} else if (decoder_reorder_pts) {
- *pts = frame->pkt_pts;
+ *pts = frame->pts;
} else {
*pts = frame->pkt_dts;
}
diff --git a/libavfilter/vsrc_movie.c b/libavfilter/vsrc_movie.c
index 95ef4f1e9c..5989a59190 100644
--- a/libavfilter/vsrc_movie.c
+++ b/libavfilter/vsrc_movie.c
@@ -228,8 +228,6 @@ static int movie_get_frame(AVFilterLink *outlink)
avcodec_decode_video2(movie->codec_ctx, movie->frame, &frame_decoded, &pkt);
if (frame_decoded) {
- if (movie->frame->pkt_pts != AV_NOPTS_VALUE)
- movie->frame->pts = movie->frame->pkt_pts;
av_log(outlink->src, AV_LOG_TRACE,
"movie_get_frame(): file:'%s' pts:%"PRId64" time:%f aspect:%d/%d\n",
movie->file_name, movie->frame->pts,