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 754889 - Fix compositor synchronization in GDK backend
Fix compositor synchronization in GDK backend
Status: RESOLVED FIXED
Product: clutter
Classification: Platform
Component: gdk
unspecified
Other All
: Normal normal
: ---
Assigned To: clutter-maint
clutter-maint
Depends on:
Blocks:
 
 
Reported: 2015-09-11 15:44 UTC by Lionel Landwerlin
Modified: 2015-09-11 22:42 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
gdk: master clock: hook ourselves to the paint signal (2.80 KB, patch)
2015-09-11 15:44 UTC, Lionel Landwerlin
committed Details | Review

Description Lionel Landwerlin 2015-09-11 15:44:50 UTC
Even though we are synchronized with the compositor in the GDK
backend, it doesn't work properly when using Clutter inside GTK+,
because we're currently hooked to the "update" signal of the
FrameClock. When embedding Clutter inside GTK+ we want to have the
layout phase of GTK+ to notify us the size of our stage before we
actually do our layout/paint phases.
Comment 1 Lionel Landwerlin 2015-09-11 15:44:55 UTC
Created attachment 311160 [details] [review]
gdk: master clock: hook ourselves to the paint signal

We're currently hooked to the "update" signal of the FrameClock. When
embedding Clutter inside GTK+ we want to have the layout phase of GTK+
to notify us the size of our stage.

This patch change to FrameClock signal we're listening to, to the
"paint" signal to make sure we've received the layout information from
GTK+, before painting. Otherwise we paint with a delay of one frame.
Comment 2 Emmanuele Bassi (:ebassi) 2015-09-11 16:25:20 UTC
Review of attachment 311160 [details] [review]:

I assume you also tested the non-embedding case, and it's still working. ;-)

In theory, it should be fine: we relayout on paint anyway, as our frame clock does not have separate phases like the GDK one.
Comment 3 Lionel Landwerlin 2015-09-11 22:37:54 UTC
Review of attachment 311160 [details] [review]:

Tested indeed :)
Comment 4 Lionel Landwerlin 2015-09-11 22:41:41 UTC
Review of attachment 311160 [details] [review]:

Pushed to master.