diff options
author | wm4 <wm4@nowhere> | 2015-08-18 22:00:40 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2015-08-18 23:00:51 +0200 |
commit | c36c596b7bc4700d05eaacdd229e8ebd3e312018 (patch) | |
tree | fb8a5be8b205d79aaf7b1832f47bfc7f027552df /video/out/gl_rpi.h | |
parent | da8a9ff5891cc55b6ea978f11761d3a30b64269c (diff) | |
download | mpv-c36c596b7bc4700d05eaacdd229e8ebd3e312018.tar.bz2 mpv-c36c596b7bc4700d05eaacdd229e8ebd3e312018.tar.xz |
rpi: factor out context creation
To be used by vo_rpi.c. No functional changes.
Diffstat (limited to 'video/out/gl_rpi.h')
-rw-r--r-- | video/out/gl_rpi.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/video/out/gl_rpi.h b/video/out/gl_rpi.h new file mode 100644 index 0000000000..e00762b632 --- /dev/null +++ b/video/out/gl_rpi.h @@ -0,0 +1,17 @@ +#include <bcm_host.h> +#include <EGL/egl.h> +#include <EGL/eglext.h> + +struct mp_egl_rpi { + struct mp_log *log; + struct GL *gl; + EGLDisplay egl_display; + EGLContext egl_context; + EGLSurface egl_surface; + // yep, the API keeps a pointer to it + EGL_DISPMANX_WINDOW_T egl_window; +}; + +int mp_egl_rpi_init(struct mp_egl_rpi *p, DISPMANX_ELEMENT_HANDLE_T window, + int w, int h); +void mp_egl_rpi_destroy(struct mp_egl_rpi *p); |