qemu-e2k/ui
Daniel P. Berrangé 69cc8db44b ui: honour the actual guest display dimensions without rounding
A long time ago the VNC server code had some memory corruption
fixes done in:

  commit bea60dd767
  Author: Peter Lieven <pl@kamp.de>
  Date:   Mon Jun 30 10:57:51 2014 +0200

    ui/vnc: fix potential memory corruption issues

One of the implications of the fix was that the VNC server would have a
thin black bad down the right hand side if the guest desktop width was
not a multiple of 16. In practice this was a non-issue since the VNC
server was always honouring a guest specified resolution and guests
essentially always pick from a small set of sane resolutions likely in
real world hardware.

We recently introduced support for the extended desktop resize extension
and as a result the VNC client has ability to specify an arbitrary
desktop size and the guest OS may well honour it exactly. As a result we
no longer have any guarantee that the width will be a multiple of 16,
and so when resizing the desktop we have a 93% chance of getting the
black bar on the right hand size.

The VNC server maintains three different desktop dimensions

 1. The guest surface
 2. The server surface
 3. The client desktop

The requirement for the width to be a multiple of 16 only applies to
item 2, the server surface, for the purpose of doing dirty bitmap
tracking.

Normally we will set the client desktop size to always match the server
surface size, but that's not a strict requirement. In order to cope with
clients that don't support the desktop size encoding, we already allow
for the client desktop to be a different size that the server surface.

Thus we can trivially eliminate the black bar, but setting the client
desktop size to be the un-rounded server surface size - the so called
"true width".

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20210311182957.486939-5-berrange@redhat.com>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2021-03-15 17:37:51 +01:00
..
icons configure: move directory options from config-host.mak to meson 2020-10-26 07:08:38 -04:00
keycodemapdb@6119e6e19a ui: update keycodemapdb submodule commit 2021-01-29 17:07:53 +00:00
shader meson: clean up build_by_default 2020-09-30 19:09:19 +02:00
cocoa.m ui/cocoa: Do not exit immediately after shutdown 2021-03-15 17:37:50 +01:00
console-gl.c opengl: Do not convert format with glTexImage2D on OpenGL ES 2021-03-15 17:37:49 +01:00
console.c ui: Replace the word 'whitelist' 2021-03-09 22:13:32 +01:00
curses_keys.h
curses.c curses: Fixes curses compiling errors. 2020-10-14 06:05:56 +02:00
cursor_hidden.xpm
cursor_left_ptr.xpm
cursor.c
egl-context.c ui: remove gl_ctx_get_current 2021-02-04 15:58:54 +01:00
egl-headless.c ui: remove gl_ctx_get_current 2021-02-04 15:58:54 +01:00
egl-helpers.c configure: Improve OpenGL dependency detections 2021-03-04 09:35:30 +01:00
gtk-egl.c configure: Improve OpenGL dependency detections 2021-03-04 09:35:30 +01:00
gtk-gl-area.c configure: Improve OpenGL dependency detections 2021-03-04 09:35:30 +01:00
gtk.c ui: mostly cocoa fixes 2021-03-12 13:53:44 +00:00
input-barrier.c input-barrier: Register properties as class properties 2020-10-13 15:56:30 -04:00
input-barrier.h
input-keymap.c meson: rename included C source files to .c.inc 2020-08-21 06:18:30 -04:00
input-legacy.c
input-linux.c machine + QOM queue, 2020-10-14 2020-10-15 16:35:06 +01:00
input.c qapi: Use QAPI_LIST_PREPEND() where possible 2020-12-19 10:20:14 +01:00
kbd-state.c
keymaps.c vl: extract softmmu/datadir.c 2020-12-10 12:15:18 -05:00
keymaps.h
meson.build configure: Improve OpenGL dependency detections 2021-03-04 09:35:30 +01:00
qemu-pixman.c
qemu-x509.h
qemu.desktop
sdl2-2d.c ui/console: Pass placeholder surface to displays 2021-03-04 09:35:36 +01:00
sdl2-gl.c ui/console: Pass placeholder surface to displays 2021-03-04 09:35:36 +01:00
sdl2-input.c
sdl2.c ui: remove gl_ctx_get_current 2021-02-04 15:58:54 +01:00
shader.c meson: convert ui directory to Meson 2020-08-21 06:30:21 -04:00
spice-app.c spice-app: avoid crash when core spice module doesn't loaded 2021-02-19 15:00:13 +01:00
spice-core.c ui: deprecate "password" option for SPICE server 2021-03-15 17:37:44 +01:00
spice-display.c ui/console: Pass placeholder surface to displays 2021-03-04 09:35:36 +01:00
spice-input.c spice: move add_interface() to QemuSpiceOps. 2020-10-21 15:46:14 +02:00
spice-module.c spice: wire up monitor in QemuSpiceOps. 2020-10-21 15:46:14 +02:00
trace-events ui: honour the actual guest display dimensions without rounding 2021-03-15 17:37:51 +01:00
trace.h trace: switch position of headers to what Meson requires 2020-08-21 06:18:24 -04:00
vgafont.h
vnc_keysym.h
vnc-auth-sasl.c ui: Replace the word 'whitelist' 2021-03-09 22:13:32 +01:00
vnc-auth-sasl.h
vnc-auth-vencrypt.c vnc: fix resource leak when websocket channel error 2020-11-04 08:25:17 +01:00
vnc-auth-vencrypt.h
vnc-enc-hextile-template.h
vnc-enc-hextile.c
vnc-enc-tight.c vnc: Remove the superfluous break 2020-09-01 08:36:53 +02:00
vnc-enc-tight.h
vnc-enc-zlib.c
vnc-enc-zrle.c meson: rename included C source files to .c.inc 2020-08-21 06:18:30 -04:00
vnc-enc-zrle.c.inc meson: rename included C source files to .c.inc 2020-08-21 06:18:30 -04:00
vnc-enc-zrle.h
vnc-enc-zywrle-template.c
vnc-enc-zywrle.h
vnc-jobs.c ui: avoid sending framebuffer updates outside client desktop bounds 2021-03-15 17:37:50 +01:00
vnc-jobs.h
vnc-palette.c
vnc-palette.h
vnc-stubs.c vnc: support "-vnc help" 2021-01-23 15:55:07 -05:00
vnc-ws.c vnc: fix resource leak when websocket channel error 2020-11-04 08:25:17 +01:00
vnc-ws.h
vnc.c ui: honour the actual guest display dimensions without rounding 2021-03-15 17:37:51 +01:00
vnc.h ui: honour the actual guest display dimensions without rounding 2021-03-15 17:37:51 +01:00
win32-kbd-hook.c
x_keymap.c nomaintainer: Fix Lesser GPL version number 2020-11-15 17:04:40 +01:00
x_keymap.h