mirror of
https://github.com/mpv-player/mpv
synced 2025-02-06 15:11:58 +00:00
vd_lavc: fix build with FFmpeg 3.2
Sigh... The functionality is not actually needed for vdpau, but if the vdpau hwaccel is present, the FFmpeg version is new enough that it includes the field.
This commit is contained in:
parent
9f268d7613
commit
19bf3a72ff
@ -591,8 +591,13 @@ static void init_avctx(struct dec_video *vd, const char *decoder,
|
||||
ctx->hwdec_dev = hwdec_create_dev(vd, ctx->hwdec, false);
|
||||
if (!ctx->hwdec_dev)
|
||||
goto error;
|
||||
if (!ctx->hwdec->set_hwframes)
|
||||
if (!ctx->hwdec->set_hwframes) {
|
||||
#if HAVE_VDPAU_HWACCEL
|
||||
avctx->hw_device_ctx = av_buffer_ref(ctx->hwdec_dev->av_device_ref);
|
||||
#else
|
||||
goto error;
|
||||
#endif
|
||||
}
|
||||
}
|
||||
ctx->max_delay_queue = ctx->hwdec->delay_queue;
|
||||
ctx->hw_probing = true;
|
||||
|
Loading…
Reference in New Issue
Block a user