summaryrefslogtreecommitdiffstats
path: root/video
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2013-12-04 20:58:06 +0100
committerwm4 <wm4@nowhere>2013-12-04 23:12:51 +0100
commit0afd121ae67a60d033fc8f74ec28bbb8b84f031d (patch)
tree8a47cf45f92f5a9c2bf4bbb19abd0d3cd09f5ded /video
parent9c2858f37ff33c72550b54270122d810284cb52b (diff)
downloadmpv-0afd121ae67a60d033fc8f74ec28bbb8b84f031d.tar.bz2
mpv-0afd121ae67a60d033fc8f74ec28bbb8b84f031d.tar.xz
vd_lavc: don't check required hwdec fields
Diffstat (limited to 'video')
-rw-r--r--video/decode/vd_lavc.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/video/decode/vd_lavc.c b/video/decode/vd_lavc.c
index fadd76de0e..b48dc7fce7 100644
--- a/video/decode/vd_lavc.c
+++ b/video/decode/vd_lavc.c
@@ -403,13 +403,12 @@ static void init_avctx(struct dec_video *vd, const char *decoder,
ctx->pic = avcodec_alloc_frame();
#endif
- if (ctx->hwdec && ctx->hwdec->allocate_image) {
+ if (ctx->hwdec) {
ctx->do_hw_dr1 = true;
avctx->thread_count = 1;
- if (ctx->hwdec->image_formats)
- avctx->get_format = get_format_hwdec;
+ avctx->get_format = get_format_hwdec;
setup_refcounting_hw(avctx);
- if (ctx->hwdec->init && ctx->hwdec->init(ctx) < 0) {
+ if (ctx->hwdec->init(ctx) < 0) {
uninit_avctx(vd);
return;
}