Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:olh:xen-4.9
qemu-2.6
qemu.fbd57c754f32804a63295f70f271d1ef128ee590.p...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File qemu.fbd57c754f32804a63295f70f271d1ef128ee590.patch of Package qemu-2.6
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 @@ -11,18 +11,18 @@ extern EGLConfig qemu_egl_config; #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 qemu_egl_rendernode_open(void); int egl_rendernode_init(void); 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(EGLNativeDisplayType dpy, bool gles, bool debug); EGLContext qemu_egl_init_ctx(void); #endif /* EGL_HELPERS_H */ --- a/ui/egl-helpers.c +++ b/ui/egl-helpers.c @@ -139,34 +139,34 @@ 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; egl_dbg("eglCreateWindowSurface (x11 win id 0x%lx) ...\n", (unsigned long) win); esurface = eglCreateWindowSurface(qemu_egl_display, qemu_egl_config, - (EGLNativeWindowType)win, NULL); + win, NULL); if (esurface == EGL_NO_SURFACE) { fprintf(stderr, "egl: eglCreateWindowSurface failed\n"); return NULL; } b = eglMakeCurrent(qemu_egl_display, esurface, esurface, ectx); if (b == EGL_FALSE) { fprintf(stderr, "egl: eglMakeCurrent failed\n"); return NULL; } return esurface; --- a/ui/gtk-egl.c +++ b/ui/gtk-egl.c @@ -55,25 +55,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