diff options
author | wm4 <wm4@nowhere> | 2016-05-10 20:37:03 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2016-05-10 21:06:34 +0200 |
commit | a3d416c3d3f578e9359fcc145989b26ccf58d190 (patch) | |
tree | 3bfc4a1fc51e9fc82b74bd5b81b3f45a15d16799 /video/out/opengl/header_fixes.h | |
parent | 4b3faf9dc1487d3a84ecc605e88452b30bc65d13 (diff) | |
download | mpv-a3d416c3d3f578e9359fcc145989b26ccf58d190.tar.bz2 mpv-a3d416c3d3f578e9359fcc145989b26ccf58d190.tar.xz |
vo_opengl: d3d11egl: native NV12 sampling support
This uses EGL_ANGLE_stream_producer_d3d_texture_nv12 and related
extensions to map the D3D textures coming from the hardware decoder
directly in GL.
In theory this would be trivial to achieve, but unfortunately ANGLE does
not have a mechanism to "import" D3D textures as GL textures. Instead,
an awkward mechanism via EGL_KHR_stream was implemented, which involves
at least 5 extensions and a lot of glue code. (Even worse than VAAPI EGL
interop, and very far from the simplicity you get on OSX.)
The ANGLE mechanism so far supports only the NV12 texture format, which
means 10 bit won't work. It also does not work in ES3 mode yet. For
these reasons, the "old" ID3D11VideoProcessor code is kept and used as a
fallback.
Diffstat (limited to 'video/out/opengl/header_fixes.h')
-rw-r--r-- | video/out/opengl/header_fixes.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/video/out/opengl/header_fixes.h b/video/out/opengl/header_fixes.h index 9f9b58f8d3..494658a64b 100644 --- a/video/out/opengl/header_fixes.h +++ b/video/out/opengl/header_fixes.h @@ -88,6 +88,11 @@ #define GL_UNSIGNED_SHORT_8_8_REV_APPLE 0x85BB #endif +// GL_OES_EGL_image_external, GL_NV_EGL_stream_consumer_external +#ifndef GL_TEXTURE_EXTERNAL_OES +#define GL_TEXTURE_EXTERNAL_OES 0x8D65 +#endif + #undef MP_GET_GL_WORKAROUNDS #endif // MP_GET_GL_WORKAROUNDS |