After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 734587 - Position gdk backend before x11/wayland/egl ones
Position gdk backend before x11/wayland/egl ones
Status: RESOLVED FIXED
Product: clutter
Classification: Platform
Component: general
git master
Other Linux
: Normal normal
: ---
Assigned To: clutter-maint
clutter-maint
Depends on:
Blocks:
 
 
Reported: 2014-08-10 19:25 UTC by Lionel Landwerlin
Modified: 2015-01-11 16:54 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
backend: try gdk backend before x11/wayland/egl (1.85 KB, patch)
2014-08-10 19:26 UTC, Lionel Landwerlin
committed Details | Review

Description Lionel Landwerlin 2014-08-10 19:25:45 UTC
Quite a few people at Guadec complained of pinpoint being broken in speaker+fullscreen mode, with slides being half displayed.
It turns out that the X11 backend of clutter was being used and this backend assumes the size of the current monitor is the size of the X screen (that's not the case with multiple monitors).

To work around the shortcomings of the X11 backend we should probably position the GDK one before. GDK implements most of the logic the ClutterStage needs and is probably more tested.

Here is a patch to position the GDK backend before the other Linux backends.
Comment 1 Lionel Landwerlin 2014-08-10 19:26:53 UTC
Created attachment 283040 [details] [review]
backend: try gdk backend before x11/wayland/egl
Comment 2 Emmanuele Bassi (:ebassi) 2014-08-12 18:59:58 UTC
Review of attachment 283040 [details] [review]:

this looks okay. we need to ensure that clutter-gtk and mutter are not broken by this change, but I'm pretty sure that:

 * clutter-gtk works just as well with the clutter gdk backend
 * mutter pre-selects the windowing system backend to x11 on initialization

which means that favouring the gdk backend is not going to regress anything out of the box.
Comment 3 Lionel Landwerlin 2014-08-13 07:16:07 UTC
Run the clutter-gtk tests, it works fine.
Comment 4 Emmanuele Bassi (:ebassi) 2014-08-13 13:17:00 UTC
so, it seems that Mutter does not in fact select the X11 backend, but only the EGL one, which means we just broke GNOME.

whoopsie.

the correct solution is for Mutter to call:

#if defined(CLUTTER_WINDOWING_X11)
 clutter_set_windowing_backend (CLUTTER_WINDOWING_X11);
#endif

on their initialization sequence, but we may have to revert the commit if that does not happen.
Comment 5 Emmanuele Bassi (:ebassi) 2014-08-13 16:35:39 UTC
mutter has been fixed by the following commit:

https://git.gnome.org/browse/mutter/commit/?id=9440bdb1aada4132d12f339d4095087806b3ed9c

    core: Select the X11 backend of ClutterHEADmaster

    Mutter depends on the X11 windowing backend of Clutter, unless it's
    used as a Wayland display server. This allows Mutter to run without
    breaking in case Clutter changes the order with which windowing
    backends are selected, like it was the case for bug
    https://bugzilla.gnome.org/show_bug.cgi?id=734587

   The order of selection of the Clutter backends has not been made
   public, so it cannot be relied upon since the introduction of the
   multiple backends support; since Mutter requires the X11 backend
   functionality, it should select the X11 windowing system, in the
   same way it selects the EGL backend when compiled and run as a
   Wayland display server.
Comment 6 Emmanuele Bassi (:ebassi) 2014-08-15 11:14:25 UTC
had to revert this because the GDK input handling does not cover touch events.

also, I started getting redraw artifacts in some cases that can be attributed to the GDK backend.

let's land this early in 3.15, and fix the issues more carefully.
Comment 7 Lionel Landwerlin 2014-08-17 09:24:14 UTC
Tried to improve the situation in clutter-gtk in https://bugzilla.gnome.org/show_bug.cgi?id=734905 and https://bugzilla.gnome.org/show_bug.cgi?id=734906 but I think there might still be some problems with Wayland, especially in the GDK backend.
Comment 9 Lionel Landwerlin 2014-08-17 16:02:06 UTC
After the fixes above, do you still see redraw artifacts?
Comment 10 Emmanuele Bassi (:ebassi) 2015-01-11 16:54:36 UTC
let's try again.