Maniphest T76720

GHOST/Wayland WM Timer Problems
Closed, ResolvedTO DO

Assigned To
Hans Goudey (HooglyBoogly)
Authored By
Hans Goudey (HooglyBoogly)
May 13 2020, 3:35 PM
Tags
  • BF Blender
  • Platform: Linux
Subscribers
Brecht Van Lommel (brecht)
Christian Rauch (christian.rauch)
Hans Goudey (HooglyBoogly)

Description

System Information
Operating system: Fedora 32
Graphics card: Mesa Intel UHD Graphics 620 (KBL GT2)

Blender Version
Broken: master WITH_GHOST_WAYLAND
Worked: never

Short description of error
When build with Wayland and running on it, panel animation only updates when the mouse is moved over the Blender window.

Exact steps for others to reproduce the error
Drag a panel in the properties area and let them animate back.

With Wayland

XWayland

Revisions and Commits

Related Objects

StatusSubtypeAssignedTask
ConfirmedTO DONone
ResolvedTO DOHans Goudey (HooglyBoogly)

Event Timeline

Hans Goudey (HooglyBoogly) created this task.May 13 2020, 3:35 PM
Hans Goudey (HooglyBoogly) added a subscriber: Christian Rauch (christian.rauch).
Hans Goudey (HooglyBoogly) changed the task status from Needs Triage to Confirmed.May 13 2020, 3:37 PM
Hans Goudey (HooglyBoogly) added a parent task: T76428: GHOST/Wayland Support.
Hans Goudey (HooglyBoogly) added a project: Platform: Linux.
Hans Goudey (HooglyBoogly) changed the subtype of this task from "Report" to "Bug".
Brecht Van Lommel (brecht) changed the subtype of this task from "Bug" to "To Do".May 13 2020, 3:46 PM
Brecht Van Lommel (brecht) added a subscriber: Brecht Van Lommel (brecht).

Marking as To Do since Wayland is still under development and is not enabled in official builds.

Christian Rauch (christian.rauch) added a comment.May 13 2020, 4:57 PM

The problem is basically that the event handling in GHOST_SystemWayland::processEvents by wl_display_dispatch blocks until new events have been received from the compositor. This is fine and efficient of the UI only has to respond to input events etc. but obviously does not work with animations or other input independent UI events.

A non-blocking alternative, such as wl_display_roundtrip, will fix this the animation issue but will result in a "busy loop" that consumes a lot of CPU.

I will have to look into another solution for this. I think a big problem is that event handling and interface rendering happens in the same thread, but that the UI drawing is not throttled by the monitor update rate.

Brecht Van Lommel (brecht) added a comment.May 13 2020, 5:27 PM

Blender as a whole works with a busy loop. While this might be changed in the future, for now Wayland should do the same as other GHOST backends and for waitForEvent argument.

Changing this assumption would require some deeper changes in Blender, and would involve Python API breakage as well.

Christian Rauch (christian.rauch) added a revision: D7658: wayland: repeat key on key press and hold.May 14 2020, 1:01 AM
Christian Rauch (christian.rauch) mentioned this in D7658: wayland: repeat key on key press and hold.May 14 2020, 1:21 AM
Christian Rauch (christian.rauch) added a comment.May 24 2020, 8:35 PM

@Hans Goudey (HooglyBoogly) This should be solved by https://developer.blender.org/D7658. Can you confirm and close this if applicable?

Hans Goudey (HooglyBoogly) closed this task as Resolved.May 24 2020, 10:37 PM
Hans Goudey (HooglyBoogly) claimed this task.

Works great! Thanks!