aboutsummaryrefslogtreecommitdiff
path: root/include/ui/console.h
diff options
context:
space:
mode:
authorMax Reitz <mreitz@redhat.com>2015-03-03 12:25:27 -0500
committerGerd Hoffmann <kraxel@redhat.com>2015-05-05 10:48:26 +0200
commite444ea34f8ec27acfa9ead7eaa9904238c831e69 (patch)
tree530949bda5134c511cdd746fbaeb4ef03cb50e7c /include/ui/console.h
parent0b71a5d5caa4f709d37fa1d7786dffc2c94f8414 (diff)
sdl2: Fix RGB555
Reproducable with: $ x86_64-softmmu/qemu-system-x86_64 \ -kernel $vmlinuz_of_your_choice \ -append vga=0x313 -sdl Signed-off-by: Max Reitz <mreitz@redhat.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'include/ui/console.h')
-rw-r--r--include/ui/console.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/ui/console.h b/include/ui/console.h
index d2116927f9..0b7589600b 100644
--- a/include/ui/console.h
+++ b/include/ui/console.h
@@ -280,6 +280,11 @@ static inline int surface_bytes_per_pixel(DisplaySurface *s)
return (bits + 7) / 8;
}
+static inline pixman_format_code_t surface_format(DisplaySurface *s)
+{
+ return s->format;
+}
+
#ifdef CONFIG_CURSES
#include <curses.h>
typedef chtype console_ch_t;