diff options
author | wm4 <wm4@nowhere> | 2017-10-30 18:33:18 +0100 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2017-10-30 18:34:49 +0100 |
commit | 58d83a93094503992a8f717c64b636450629555c (patch) | |
tree | c923d5f99958264bd66ec5466fe681324215ad4d /video/decode/lavc.h | |
parent | b7ce3ac44575d82b5b23f10477b1158b84394b8f (diff) | |
download | mpv-58d83a93094503992a8f717c64b636450629555c.tar.bz2 mpv-58d83a93094503992a8f717c64b636450629555c.tar.xz |
vd_lavc: make --hwdec=nvdec-copy actually work
This simply didn't work. Unlike cuda-copy, this is a true hwaccel, and
obviously we need to provide it a device.
Implement this in a relatively generic way, which can probably reused
directly by videotoolbox (not doing this yet because it would require
testing on OSX).
Like with cuda-copy, --cuda-decode-device is ignored. We might be able
to provide a more general way to select devices at some later point.
Diffstat (limited to 'video/decode/lavc.h')
-rw-r--r-- | video/decode/lavc.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/video/decode/lavc.h b/video/decode/lavc.h index 6287dc8577..810d7e393c 100644 --- a/video/decode/lavc.h +++ b/video/decode/lavc.h @@ -87,6 +87,10 @@ struct vd_lavc_hwdec { enum hwdec_type type; // If non-0, get this hwdec type from the VO (for the AVHWDeviceContext). enum hwdec_type interop_type; + // If true, create a AVHWDeviceContext with default parameters. In this + // case, create_standalone_dev_type is set to a valid value. + bool create_standalone_dev; + enum AVHWDeviceType create_standalone_dev_type; // If not-0: the IMGFMT_ format that should be accepted in the libavcodec // get_format callback. int image_format; |