-
Notifications
You must be signed in to change notification settings - Fork 94
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DPMS with wlr-output-power-management-unstable-v1
protocol
#741
Conversation
With this current, simple, way of settings the DPMS state, it does seem to spend .5 to 1 second in the call for some reason... seems excessive, but definitely should be handled in the render thread of that surface anyway. I also see page flip errors. Presumably we just shouldn't attempt page flips when we have DPMS set to off. (And also disable/throttle frame callbacks. And don't actually try to render.) |
Looking at wlroots/mutter/kwin and DRM documentation, I guess we shouldn't set the
|
wlr-output-power-management-unstable-v1
protocolwlr-output-power-management-unstable-v1
protocol
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As discussed on mattermost, this needs a way for the compositor to clear the suspension, when the user isn't idling anymore, but otherwise this looks good and quite straight-forward!
state.loop_handle.remove(estimated_vblank); | ||
state.loop_handle.remove(queued_render); | ||
} | ||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hmm, at some point we might want to refactor this into a reset method, but that is fine for now.
Trying to test mirroring here, I ran into a few unrelated issues with cosmic-randr/mirroring (pop-os/cosmic-randr#33, pop-os/cosmic-randr#34). I think this should be good now, after changing a few things:
|
This works to set DPMS on or off. It still needs to track the DPMS state and send events to clients when the mode changes. And otherwise be cleaned up a bit.
Components like
cosmic-greeter
may make use of this.This can be tested with the below code (which also works on Sway):