aboutsummaryrefslogtreecommitdiffhomepage
path: root/video/decode/hw_vdpau.c
diff options
context:
space:
mode:
authorGravatar wm4 <wm4@nowhere>2017-03-14 23:29:47 +0100
committerGravatar wm4 <wm4@nowhere>2017-03-14 23:29:47 +0100
commit4e384c8e69422acf593fc7b2a0c1d512c3e5966e (patch)
tree1f7964f08e96b8e117072f319f3b3740c0d87a71 /video/decode/hw_vdpau.c
parent94e82bcdb82dfedbb01978a68204c7ecd24d6b6c (diff)
vdpau: warn on HEVC due to completely broken nVidia drivers
I guess that's the full extent I still care about nVidia's broken garbage. In theory, we could always force the video mixer (which is the only method getting the video data that works), but why bother.
Diffstat (limited to 'video/decode/hw_vdpau.c')
-rw-r--r--video/decode/hw_vdpau.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/video/decode/hw_vdpau.c b/video/decode/hw_vdpau.c
index 6047ef1360..e47893f19a 100644
--- a/video/decode/hw_vdpau.c
+++ b/video/decode/hw_vdpau.c
@@ -51,10 +51,13 @@ static int init_decoder(struct lavc_ctx *ctx, int w, int h)
if (mp_vdpau_handle_preemption(p->mpvdp, &p->preemption_counter) < 0)
return 0;
- return av_vdpau_bind_context(ctx->avctx, p->mpvdp->vdp_device,
- p->mpvdp->get_proc_address,
- AV_HWACCEL_FLAG_IGNORE_LEVEL |
- AV_HWACCEL_FLAG_ALLOW_HIGH_DEPTH);
+ int r = av_vdpau_bind_context(ctx->avctx, p->mpvdp->vdp_device,
+ p->mpvdp->get_proc_address,
+ AV_HWACCEL_FLAG_IGNORE_LEVEL |
+ AV_HWACCEL_FLAG_ALLOW_HIGH_DEPTH);
+ if (r >= 0 && ctx->avctx->codec_id == AV_CODEC_ID_HEVC)
+ MP_WARN(ctx, "HEVC video output may be broken due to nVidia bugs.\n");
+ return r;
}
static void uninit(struct lavc_ctx *ctx)