summaryrefslogtreecommitdiff
path: root/libavcodec/h264_picture.c
diff options
context:
space:
mode:
Diffstat (limited to 'libavcodec/h264_picture.c')
-rw-r--r--libavcodec/h264_picture.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libavcodec/h264_picture.c b/libavcodec/h264_picture.c
index 04bbf028cc..731d780e67 100644
--- a/libavcodec/h264_picture.c
+++ b/libavcodec/h264_picture.c
@@ -157,9 +157,11 @@ int ff_h264_field_end(H264Context *h, H264SliceContext *sl, int in_setup)
int err = 0;
h->mb_y = 0;
+#if FF_API_CAP_VDPAU
if (CONFIG_H264_VDPAU_DECODER &&
h->avctx->codec->capabilities & AV_CODEC_CAP_HWACCEL_VDPAU)
ff_vdpau_h264_set_reference_frames(h);
+#endif
if (in_setup || !(avctx->active_thread_type & FF_THREAD_FRAME)) {
if (!h->droppable) {
@@ -178,9 +180,11 @@ int ff_h264_field_end(H264Context *h, H264SliceContext *sl, int in_setup)
"hardware accelerator failed to decode picture\n");
}
+#if FF_API_CAP_VDPAU
if (CONFIG_H264_VDPAU_DECODER &&
h->avctx->codec->capabilities & AV_CODEC_CAP_HWACCEL_VDPAU)
ff_vdpau_h264_picture_complete(h);
+#endif
#if CONFIG_ERROR_RESILIENCE
av_assert0(sl == h->slice_ctx);