target-arm: lpae: Move declaration of t0sz and t1sz
[qemu/ar7.git] / ui / egl-context.c
blob40102e392e1f57d2f23545fe4df54ed9d9f010d2
1 #include "qemu-common.h"
2 #include "ui/egl-context.h"
4 QEMUGLContext qemu_egl_create_context(DisplayChangeListener *dcl,
5 QEMUGLParams *params)
7 EGLContext ctx;
8 EGLint ctx_att[] = {
9 EGL_CONTEXT_CLIENT_VERSION, params->major_ver,
10 EGL_CONTEXT_MINOR_VERSION_KHR, params->minor_ver,
11 EGL_NONE
14 ctx = eglCreateContext(qemu_egl_display, qemu_egl_config,
15 eglGetCurrentContext(), ctx_att);
16 return ctx;
19 void qemu_egl_destroy_context(DisplayChangeListener *dcl, QEMUGLContext ctx)
21 eglDestroyContext(qemu_egl_display, ctx);
24 int qemu_egl_make_context_current(DisplayChangeListener *dcl,
25 QEMUGLContext ctx)
27 return eglMakeCurrent(qemu_egl_display,
28 EGL_NO_SURFACE, EGL_NO_SURFACE, ctx);
31 QEMUGLContext qemu_egl_get_current_context(DisplayChangeListener *dcl)
33 return eglGetCurrentContext();