aboutsummaryrefslogtreecommitdiffstats
path: root/console.h
diff options
context:
space:
mode:
authorStefano Stabellini <stefano.stabellini@eu.citrix.com>2009-06-24 11:58:25 +0100
committerAnthony Liguori <aliguori@us.ibm.com>2009-06-29 08:52:44 -0500
commitc18a2c360e3100bbd71162cf922dcd8c429a8b71 (patch)
treedea997d9de9b100224a2f2adf25dead03d47df34 /console.h
parent14899cdf3a6e1fc0d72097a43c1c53a1354fbfbf (diff)
sdl zooming
Hi all, this patch implements zooming capabilities for the sdl interface. A new sdl_zoom_blit function is added that is able to scale and blit a portion of a surface into another. This way we can enable SDL_RESIZABLE and have a real_screen surface with a different size than the guest surface and let sdl_zoom_blit take care of the problem. Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'console.h')
-rw-r--r--console.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/console.h b/console.h
index 417217582..35183399f 100644
--- a/console.h
+++ b/console.h
@@ -75,6 +75,7 @@ void kbd_put_keysym(int keysym);
#define QEMU_BIG_ENDIAN_FLAG 0x01
#define QEMU_ALLOCATED_FLAG 0x02
+#define QEMU_REALPIXELS_FLAG 0x04
struct PixelFormat {
uint8_t bits_per_pixel;
@@ -172,7 +173,8 @@ static inline int is_surface_bgr(DisplaySurface *surface)
static inline int is_buffer_shared(DisplaySurface *surface)
{
- return (!(surface->flags & QEMU_ALLOCATED_FLAG));
+ return (!(surface->flags & QEMU_ALLOCATED_FLAG) &&
+ !(surface->flags & QEMU_REALPIXELS_FLAG));
}
static inline void register_displaychangelistener(DisplayState *ds, DisplayChangeListener *dcl)