mirror of
https://github.com/yshui/picom.git
synced 2024-11-11 13:51:02 -05:00
backend: egl: fix creating eglpixmap
according to the specification of the EGL_KHR_image_pixmap extension, if target is EGL_NATIVE_PIXMAP_KHR then ctx must be EGL_NO_CONTEXT, otherwise, the EGL_BAD_PARAMETER error is generated. source: https://registry.khronos.org/EGL/extensions/KHR/EGL_KHR_image_pixmap.txt fixes #981
This commit is contained in:
parent
60ac2b64db
commit
0ecfd9fd32
1 changed files with 3 additions and 2 deletions
|
@ -285,8 +285,9 @@ egl_bind_pixmap(backend_t *base, xcb_pixmap_t pixmap, struct xvisual_info fmt, b
|
|||
|
||||
eglpixmap = cmalloc(struct egl_pixmap);
|
||||
eglpixmap->pixmap = pixmap;
|
||||
eglpixmap->image = eglCreateImageProc(gd->display, gd->ctx, EGL_NATIVE_PIXMAP_KHR,
|
||||
(EGLClientBuffer)(uintptr_t)pixmap, NULL);
|
||||
eglpixmap->image =
|
||||
eglCreateImageProc(gd->display, EGL_NO_CONTEXT, EGL_NATIVE_PIXMAP_KHR,
|
||||
(EGLClientBuffer)(uintptr_t)pixmap, NULL);
|
||||
eglpixmap->owned = owned;
|
||||
|
||||
if (eglpixmap->image == EGL_NO_IMAGE) {
|
||||
|
|
Loading…
Reference in a new issue