diff options
author | Juraj Marcin <jmarcin@redhat.com> | 2025-05-21 17:16:13 +0200 |
---|---|---|
committer | Peter Xu <peterx@redhat.com> | 2025-06-23 16:03:59 -0400 |
commit | 0310d594d98b39f9dde79b87fd8b0ad16e7c5459 (patch) | |
tree | 14e46d69856f93f58274dadd95db3180b5b22105 /scripts/qapi/source.py | |
parent | 8120decfb593c386e053a1ac9723e75bd181dbff (diff) | |
download | qemu-0310d594d98b39f9dde79b87fd8b0ad16e7c5459.zip qemu-0310d594d98b39f9dde79b87fd8b0ad16e7c5459.tar.gz qemu-0310d594d98b39f9dde79b87fd8b0ad16e7c5459.tar.bz2 |
ui/vnc: Update display update interval when VM state changes to RUNNING
If a virtual machine is paused for an extended period time, for example,
due to an incoming migration, there are also no changes on the screen.
VNC in such case increases the display update interval by
VNC_REFRESH_INTERVAL_INC (50 ms). The update interval can then grow up
to VNC_REFRESH_INTERVAL_MAX (3000 ms).
When the machine resumes, it can then take up to 3 seconds for the first
display update. Furthermore, the update interval is then halved with
each display update with changes on the screen. If there are moving
elements on the screen, such as a video, this can be perceived as
freezing and stuttering for few seconds before the movement is smooth
again.
This patch resolves this issue, by adding a listener to VM state changes
and changing the update interval when the VM state changes to RUNNING.
The update_displaychangelistener() function updates the internal timer,
and the display is refreshed immediately if the timer is expired.
Signed-off-by: Juraj Marcin <jmarcin@redhat.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Link: https://lore.kernel.org/r/20250521151616.3951178-1-jmarcin@redhat.com
Signed-off-by: Peter Xu <peterx@redhat.com>
Diffstat (limited to 'scripts/qapi/source.py')
0 files changed, 0 insertions, 0 deletions