Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:olh:xen-4.7
qemu-2.10
qemu.fbd57c754f32804a63295f70f271d1ef128ee590.p...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File qemu.fbd57c754f32804a63295f70f271d1ef128ee590.patch of Package qemu-2.10
From: Alexander Kanavin <alex.kanavin@gmail.com> Date: Wed, 16 Jan 2019 12:37:51 +0100 Subject: fbd57c754f32804a63295f70f271d1ef128ee590 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit egl-helpers.h: do not depend on X11 Window type, use EGLNativeWindowType It was assumed that mesa provides the necessary X11 includes, but it is not always the case, as it can be configured without x11 support. Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com> Message-id: 20190116113751.17177-1-alex.kanavin@gmail.com [ kraxel: codestyle fix (long line) ] Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> --- include/ui/egl-helpers.h | 2 +- ui/egl-helpers.c | 4 ++-- ui/gtk-egl.c | 3 ++- 3 files changed, 5 insertions(+), 4 deletions(-) --- a/include/ui/egl-helpers.h +++ b/include/ui/egl-helpers.h @@ -25,19 +25,19 @@ void egl_fb_read(void *dst, egl_fb *src); #ifdef CONFIG_OPENGL_DMABUF extern int qemu_egl_rn_fd; extern struct gbm_device *qemu_egl_rn_gbm_dev; extern EGLContext qemu_egl_rn_ctx; int egl_rendernode_init(const char *rendernode); int egl_get_fd_for_texture(uint32_t tex_id, EGLint *stride, EGLint *fourcc); #endif -EGLSurface qemu_egl_init_surface_x11(EGLContext ectx, Window win); +EGLSurface qemu_egl_init_surface_x11(EGLContext ectx, EGLNativeWindowType win); int qemu_egl_init_dpy_x11(EGLNativeDisplayType dpy); int qemu_egl_init_dpy_mesa(EGLNativeDisplayType dpy); EGLContext qemu_egl_init_ctx(void); #endif /* EGL_HELPERS_H */ --- a/ui/egl-helpers.c +++ b/ui/egl-helpers.c @@ -226,32 +226,32 @@ int egl_get_fd_for_texture(uint32_t tex_id, EGLint *stride, EGLint *fourcc) return -1; } eglExportDMABUFImageMESA(qemu_egl_display, image, &fd, stride, NULL); eglDestroyImageKHR(qemu_egl_display, image); return fd; } #endif /* CONFIG_OPENGL_DMABUF */ /* ---------------------------------------------------------------------- */ -EGLSurface qemu_egl_init_surface_x11(EGLContext ectx, Window win) +EGLSurface qemu_egl_init_surface_x11(EGLContext ectx, EGLNativeWindowType win) { EGLSurface esurface; EGLBoolean b; esurface = eglCreateWindowSurface(qemu_egl_display, qemu_egl_config, - (EGLNativeWindowType)win, NULL); + win, NULL); if (esurface == EGL_NO_SURFACE) { error_report("egl: eglCreateWindowSurface failed"); return NULL; } b = eglMakeCurrent(qemu_egl_display, esurface, esurface, ectx); if (b == EGL_FALSE) { error_report("egl: eglMakeCurrent failed"); return NULL; } return esurface; --- a/ui/gtk-egl.c +++ b/ui/gtk-egl.c @@ -48,25 +48,26 @@ void gd_egl_init(VirtualConsole *vc) } #if GTK_CHECK_VERSION(3, 0, 0) Window x11_window = gdk_x11_window_get_xid(gdk_window); #else Window x11_window = gdk_x11_drawable_get_xid(gdk_window); #endif if (!x11_window) { return; } vc->gfx.ectx = qemu_egl_init_ctx(); - vc->gfx.esurface = qemu_egl_init_surface_x11(vc->gfx.ectx, x11_window); + vc->gfx.esurface = qemu_egl_init_surface_x11 + (vc->gfx.ectx, (EGLNativeWindowType)x11_window); assert(vc->gfx.esurface); } void gd_egl_draw(VirtualConsole *vc) { GdkWindow *window; int ww, wh; if (!vc->gfx.gls) { return; }
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor