summaryrefslogtreecommitdiffstats
path: root/video/decode
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2017-01-16 19:58:40 +0100
committerwm4 <wm4@nowhere>2017-01-16 19:58:40 +0100
commit64041f963e7214fc07b62c834050419303fe1595 (patch)
tree7754b9db004f9c83025a5725ff91ecac2b25f1d0 /video/decode
parentfb6481ecb5e3a950fbec3ae76ad29352576b2aaf (diff)
downloadmpv-64041f963e7214fc07b62c834050419303fe1595.tar.bz2
mpv-64041f963e7214fc07b62c834050419303fe1595.tar.xz
cuda: fix 10 bit decoding
Messy mess. Unsure whether this will be resolved properly in FFmpeg.
Diffstat (limited to 'video/decode')
-rw-r--r--video/decode/cuda.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/video/decode/cuda.c b/video/decode/cuda.c
index d1fd2941c2..92ba0772c4 100644
--- a/video/decode/cuda.c
+++ b/video/decode/cuda.c
@@ -60,12 +60,18 @@ static int init_decoder(struct lavc_ctx *ctx, int w, int h)
AVHWFramesContext *hwframe_ctx = (void* )avctx->hw_frames_ctx->data;
hwframe_ctx->format = AV_PIX_FMT_CUDA;
+
+ // This is proper use of the hw_frames_ctx API, but it does not work
+ // (appaears to work but fails e.g. with 10 bit). The cuvid wrapper
+ // does non-standard things, and it's a meesy situation.
+ /*
hwframe_ctx->width = w;
hwframe_ctx->height = h;
hwframe_ctx->sw_format = avctx->sw_pix_fmt;
if (av_hwframe_ctx_init(avctx->hw_frames_ctx) < 0)
goto error;
+ */
return 0;