Closed Bug 1467127 Opened 2 years ago Closed 7 months ago
[Wayland] Integrate wl
_display _dispatch _queue _pending() with compositor thread event loop
47 bytes, text/x-phabricator-request
|Details | Review|
Integrate wl_display_dispatch_queue_pending() with compositor thread event loop and remove the fixed fps here.
Some more context from Jonas Adahl: > I'll try to look at it but I'm afraid I'd need to call the > wl_display_dispatch_queue_pending() in some fps-based loop anyway. It is possible to integrate the libwayland-client dispatch code into other main loops. See gtk+/gdk/wayland/gdkeventsource.c for how it's done for GLib; I imagine it should be possible to do it in the one used in Firefox too in a similar way. > - make sure we don't miss Wayland events (call > wl_display_dispatch_queue_pending() or use the code you posted). You should always use the prepare_read/read/dispatch_pending API otherwise you may end up with frame drops and unnecessary latency as 1) You rely on the main thread to read the events, 2) You have no way to know when new events will come.
We also should call wl_display_dispatch_queue_pending() before getting new buffer as well as elg/drivers/dri2/platform_wayland.c does.
Assignee: stransky → nobody
Attachment #9058281 - Attachment is obsolete: true
Assignee: nobody → bugzilla
You need to log in before you can comment on or make changes to this bug.