summaryrefslogtreecommitdiff
path: root/codec.c
diff options
context:
space:
mode:
authorJohns <johns98@gmx.net>2014-05-30 10:18:20 +0200
committerJohns <johns98@gmx.net>2014-05-30 10:18:20 +0200
commitac7672053a9d185544e7a93deac770e15d57ae93 (patch)
treea7e584a8a932e9ea5cde9ce201a4b91c53463a38 /codec.c
parent0cdedb88acfc7c77fafefe2d93598db04a01f1ac (diff)
downloadvdr-plugin-softhddevice-ac7672053a9d185544e7a93deac770e15d57ae93.tar.gz
vdr-plugin-softhddevice-ac7672053a9d185544e7a93deac770e15d57ae93.tar.bz2
Fix out of sync with ffmpeg >= 2.2.
This workaround for some special ffmpeg versions, conflicts with latest ffmpeg.
Diffstat (limited to 'codec.c')
-rw-r--r--codec.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/codec.c b/codec.c
index be6ed29..b6f9fba 100644
--- a/codec.c
+++ b/codec.c
@@ -222,12 +222,14 @@ static int Codec_get_buffer(AVCodecContext * video_ctx, AVFrame * frame)
frame->data[2] = NULL;
frame->data[3] = NULL;
+#if LIBAVUTIL_VERSION_INT < AV_VERSION_INT(52,66,100)
// reordered frames
if (video_ctx->pkt) {
frame->pkt_pts = video_ctx->pkt->pts;
} else {
frame->pkt_pts = AV_NOPTS_VALUE;
}
+#endif
return 0;
}
#endif
@@ -249,12 +251,14 @@ static int Codec_get_buffer(AVCodecContext * video_ctx, AVFrame * frame)
frame->data[0] = (void *)(size_t) surface;
frame->data[3] = (void *)(size_t) surface;
+#if LIBAVUTIL_VERSION_INT < AV_VERSION_INT(52,66,100)
// reordered frames
if (video_ctx->pkt) {
frame->pkt_pts = video_ctx->pkt->pts;
} else {
frame->pkt_pts = AV_NOPTS_VALUE;
}
+#endif
return 0;
}
//Debug(3, "codec: fallback to default get_buffer\n");