Commit Graph

3 Commits

Author SHA1 Message Date
Hans de Goede
741bd73429 glamor/xwayland: Define EGL_NO_X11
Define EGL_NO_X11 everywhere were we also define MESA_EGL_NO_X11_HEADERS,
EGL_NO_X11 is the MESA_EGL_NO_X11_HEADERS equivalent for the egl headers
shipped with libglvnd.

This fixes the xserver not building with the libglvnd-1.2.0 headers:

In file included from /usr/include/EGL/eglplatform.h:128,
                 from /usr/include/epoxy/egl_generated.h:11,
                 from /usr/include/epoxy/egl.h:46,
                 from glamor_priv.h:43,
                 from glamor_composite_glyphs.c:25:
/usr/include/X11/Xlib.h:222:2: error: conflicting types for 'GC'
  222 | *GC;
      |  ^~
In file included from glamor.h:34,
                 from glamor_priv.h:32,
                 from glamor_composite_glyphs.c:25:
../include/gcstruct.h:282:3: note: previous declaration of 'GC' was here
  282 | } GC;
      |   ^~

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2019-11-04 20:49:33 +01:00
Adam Jackson
0dc0cef495 xwayland-glx: Fix GLX visual mask setup
a2rgb10 configs would end up with channel masks corresponding to
argb8888. This would confuse the GLX core code into matching an a2rgb10
config to the root window visual, and that would make things look wrong
and bad.

Fix this by handling more cases. We're still not fully general here, and
this could still be wrong on big-endian. The XXX comment about doing
something less ugly still applies, ideally we would get this information
out of EGL instead of making lucky guesses. Still, better than it was.

Fixes: xorg/xserver#824
2019-06-18 14:57:16 -04:00
Adam Jackson
8469241592 xwayland: Add EGL-backed GLX provider
Without this we're using driswrast to set up GLX visuals. This is
unfortunate because llvmpipe does not expose multisample configs, so
various apps that expect them will fail. With this we just query the
capabilities of the EGL that's backing glamor, and reflect that to the
GLX clients. This also paves the way for xserver to stop being a DRI
driver loader, which is nice.

Fixes: xorg/xserver#640
Fixes: xorg/xserver#643
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=98272
Reviewed-by: Olivier Fourdan <ofourdan@redhat.com>
Signed-off-by: Adam Jackson <ajax@redhat.com>
2019-05-23 12:39:39 -04:00