Merge remote-tracking branch 'kraxel/pixman.v3' into staging

* kraxel/pixman.v3: (22 commits)
  pixman: drop obsolete fields from DisplaySurface
  pixman/vnc: remove dead code.
  pixman/vnc: remove rgb_prepare_row* functions
  pixman/vnc: use pixman images in vnc.
  pixman: switch screendump function.
  vga: stop direct access to DisplaySurface fields.
  qxl: stop direct access to DisplaySurface fields.
  console: don't set PixelFormat alpha fields for 32bpp
  console: make qemu_alloc_display static
  pixman: add pixman image to DisplaySurface
  pixman: helper functions
  pixman: windup in configure & makefiles
  pixman: add submodule
  console: remove DisplayAllocator
  console: remove dpy_gfx_fill
  vga: fix text mode updating
  console: init displaychangelisteners on register
  console: untangle gfx & txt updates
  console: s/TextConsole/QemuConsole/
  console: move set_mouse + cursor_define callbacks
  ...

Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
This commit is contained in:
Anthony Liguori
2012-11-01 11:14:39 -05:00
43 changed files with 857 additions and 864 deletions
+3
View File
@@ -19,3 +19,6 @@
[submodule "roms/sgabios"]
path = roms/sgabios
url = git://git.qemu.org/sgabios.git
[submodule "pixman"]
path = pixman
url = git://anongit.freedesktop.org/pixman
+9
View File
@@ -118,6 +118,15 @@ endif
subdir-libcacard: $(oslib-obj-y) $(trace-obj-y) qemu-timer-common.o
subdir-pixman: pixman/Makefile
$(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) -C pixman V="$(V)" all,)
pixman/Makefile: $(SRC_PATH)/pixman/configure
(cd pixman; $(SRC_PATH)/pixman/configure --disable-shared --enable-static)
$(SRC_PATH)/pixman/configure:
(cd $(SRC_PATH)/pixman; autoreconf -v --install)
$(filter %-softmmu,$(SUBDIR_RULES)): $(universal-obj-y) $(trace-obj-y) $(common-obj-y) $(extra-obj-y) subdir-libdis
$(filter %-user,$(SUBDIR_RULES)): $(universal-obj-y) $(trace-obj-y) subdir-libdis-user subdir-libuser
+1
View File
@@ -65,6 +65,7 @@ common-obj-y = $(block-obj-y) blockdev.o blockdev-nbd.o block/
common-obj-y += net.o net/
common-obj-y += qom/
common-obj-y += readline.o console.o cursor.o
common-obj-y += qemu-pixman.o
common-obj-y += $(oslib-obj-y)
common-obj-$(CONFIG_WIN32) += os-win32.o
common-obj-$(CONFIG_POSIX) += os-posix.o
Vendored
+38
View File
@@ -147,6 +147,7 @@ curses=""
docs=""
fdt=""
nptl=""
pixman=""
sdl=""
virtfs=""
vnc="yes"
@@ -642,6 +643,10 @@ for opt do
# configure to be used by RPM and similar macros that set
# lots of directory switches by default.
;;
--with-system-pixman) pixman="system"
;;
--without-system-pixman) pixman="internal"
;;
--disable-sdl) sdl="no"
;;
--enable-sdl) sdl="yes"
@@ -2094,6 +2099,34 @@ else
exit 1
fi
##########################################
# pixman support probe
if test "$pixman" = ""; then
if $pkg_config pixman-1 > /dev/null 2>&1; then
pixman="system"
else
pixman="internal"
fi
fi
if test "$pixman" = "system"; then
pixman_cflags=`$pkg_config --cflags pixman-1 2>/dev/null`
pixman_libs=`$pkg_config --libs pixman-1 2>/dev/null`
else
if test ! -d ${source_path}/pixman/pixman; then
echo "ERROR: pixman not present. Your options:"
echo " (1) Prefered: Install the pixman devel package (any recent"
echo " distro should have packages as Xorg needs pixman too)."
echo " (2) Fetch the pixman submodule, using:"
echo " git submodule update --init pixman"
exit 1
fi
pixman_cflags="-I${source_path}/pixman/pixman"
pixman_libs="-Lpixman/pixman/.libs -lpixman-1"
fi
QEMU_CFLAGS="$QEMU_CFLAGS $pixman_cflags"
libs_softmmu="$libs_softmmu $pixman_libs"
##########################################
# libcap probe
@@ -3142,6 +3175,7 @@ echo "-Werror enabled $werror"
if test "$darwin" = "yes" ; then
echo "Cocoa support $cocoa"
fi
echo "pixman $pixman"
echo "SDL support $sdl"
echo "curses support $curses"
echo "curl support $curl"
@@ -3908,6 +3942,9 @@ if test "$target_softmmu" = "yes" ; then
if test "$smartcard_nss" = "yes" ; then
echo "subdir-$target: subdir-libcacard" >> $config_host_mak
fi
if test "$pixman" = "internal" ; then
echo "subdir-$target: subdir-pixman" >> $config_host_mak
fi
case "$target_arch2" in
i386|x86_64)
echo "CONFIG_HAVE_CORE_DUMP=y" >> $config_target_mak
@@ -4111,6 +4148,7 @@ DIRS="$DIRS pc-bios/optionrom pc-bios/spapr-rtas"
DIRS="$DIRS roms/seabios roms/vgabios"
DIRS="$DIRS qapi-generated"
DIRS="$DIRS libcacard libcacard/libcacard libcacard/trace"
DIRS="$DIRS pixman"
FILES="Makefile tests/tcg/Makefile qdict-test-data.txt"
FILES="$FILES tests/tcg/cris/Makefile tests/tcg/cris/.gdbinit"
FILES="$FILES tests/tcg/lm32/Makefile libcacard/Makefile"
+120 -132
View File
File diff suppressed because it is too large Load Diff
+142 -95
View File
@@ -2,6 +2,7 @@
#define CONSOLE_H
#include "qemu-char.h"
#include "qemu-pixman.h"
#include "qdict.h"
#include "notify.h"
#include "monitor.h"
@@ -107,7 +108,6 @@ 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;
@@ -120,11 +120,9 @@ struct PixelFormat {
};
struct DisplaySurface {
pixman_format_code_t format;
pixman_image_t *image;
uint8_t flags;
int width;
int height;
int linesize; /* bytes per line */
uint8_t *data;
struct PixelFormat pf;
};
@@ -154,35 +152,32 @@ struct DisplayChangeListener {
int idle;
uint64_t gui_timer_interval;
void (*dpy_update)(struct DisplayState *s, int x, int y, int w, int h);
void (*dpy_resize)(struct DisplayState *s);
void (*dpy_setdata)(struct DisplayState *s);
void (*dpy_refresh)(struct DisplayState *s);
void (*dpy_copy)(struct DisplayState *s, int src_x, int src_y,
int dst_x, int dst_y, int w, int h);
void (*dpy_fill)(struct DisplayState *s, int x, int y,
int w, int h, uint32_t c);
void (*dpy_gfx_update)(struct DisplayState *s, int x, int y, int w, int h);
void (*dpy_gfx_resize)(struct DisplayState *s);
void (*dpy_gfx_setdata)(struct DisplayState *s);
void (*dpy_gfx_copy)(struct DisplayState *s, int src_x, int src_y,
int dst_x, int dst_y, int w, int h);
void (*dpy_text_cursor)(struct DisplayState *s, int x, int y);
void (*dpy_text_resize)(struct DisplayState *s, int w, int h);
void (*dpy_text_update)(struct DisplayState *s, int x, int y, int w, int h);
struct DisplayChangeListener *next;
};
void (*dpy_mouse_set)(struct DisplayState *s, int x, int y, int on);
void (*dpy_cursor_define)(struct DisplayState *s, QEMUCursor *cursor);
struct DisplayAllocator {
DisplaySurface* (*create_displaysurface)(int width, int height);
DisplaySurface* (*resize_displaysurface)(DisplaySurface *surface, int width, int height);
void (*free_displaysurface)(DisplaySurface *surface);
QLIST_ENTRY(DisplayChangeListener) next;
};
struct DisplayState {
struct DisplaySurface *surface;
void *opaque;
struct QEMUTimer *gui_timer;
bool have_gfx;
bool have_text;
struct DisplayAllocator* allocator;
struct DisplayChangeListener* listeners;
void (*mouse_set)(int x, int y, int on);
void (*cursor_define)(QEMUCursor *cursor);
QLIST_HEAD(, DisplayChangeListener) listeners;
struct DisplayState *next;
};
@@ -191,29 +186,14 @@ void register_displaystate(DisplayState *ds);
DisplayState *get_displaystate(void);
DisplaySurface* qemu_create_displaysurface_from(int width, int height, int bpp,
int linesize, uint8_t *data);
void qemu_alloc_display(DisplaySurface *surface, int width, int height,
int linesize, PixelFormat pf, int newflags);
PixelFormat qemu_different_endianness_pixelformat(int bpp);
PixelFormat qemu_default_pixelformat(int bpp);
DisplayAllocator *register_displayallocator(DisplayState *ds, DisplayAllocator *da);
static inline DisplaySurface* qemu_create_displaysurface(DisplayState *ds, int width, int height)
{
return ds->allocator->create_displaysurface(width, height);
}
static inline DisplaySurface* qemu_resize_displaysurface(DisplayState *ds, int width, int height)
{
trace_displaysurface_resize(ds, ds->surface, width, height);
return ds->allocator->resize_displaysurface(ds->surface, width, height);
}
static inline void qemu_free_displaysurface(DisplayState *ds)
{
trace_displaysurface_free(ds, ds->surface);
ds->allocator->free_displaysurface(ds->surface);
}
DisplaySurface *qemu_create_displaysurface(DisplayState *ds,
int width, int height);
DisplaySurface *qemu_resize_displaysurface(DisplayState *ds,
int width, int height);
void qemu_free_displaysurface(DisplayState *ds);
static inline int is_surface_bgr(DisplaySurface *surface)
{
@@ -225,109 +205,176 @@ static inline int is_surface_bgr(DisplaySurface *surface)
static inline int is_buffer_shared(DisplaySurface *surface)
{
return (!(surface->flags & QEMU_ALLOCATED_FLAG) &&
!(surface->flags & QEMU_REALPIXELS_FLAG));
return !(surface->flags & QEMU_ALLOCATED_FLAG);
}
void gui_setup_refresh(DisplayState *ds);
static inline void register_displaychangelistener(DisplayState *ds, DisplayChangeListener *dcl)
{
dcl->next = ds->listeners;
ds->listeners = dcl;
}
static inline void dpy_update(DisplayState *s, int x, int y, int w, int h)
{
struct DisplayChangeListener *dcl = s->listeners;
while (dcl != NULL) {
dcl->dpy_update(s, x, y, w, h);
dcl = dcl->next;
QLIST_INSERT_HEAD(&ds->listeners, dcl, next);
gui_setup_refresh(ds);
if (dcl->dpy_gfx_resize) {
dcl->dpy_gfx_resize(ds);
}
}
static inline void dpy_resize(DisplayState *s)
static inline void unregister_displaychangelistener(DisplayState *ds,
DisplayChangeListener *dcl)
{
struct DisplayChangeListener *dcl = s->listeners;
while (dcl != NULL) {
dcl->dpy_resize(s);
dcl = dcl->next;
QLIST_REMOVE(dcl, next);
gui_setup_refresh(ds);
}
static inline void dpy_gfx_update(DisplayState *s, int x, int y, int w, int h)
{
struct DisplayChangeListener *dcl;
QLIST_FOREACH(dcl, &s->listeners, next) {
if (dcl->dpy_gfx_update) {
dcl->dpy_gfx_update(s, x, y, w, h);
}
}
}
static inline void dpy_setdata(DisplayState *s)
static inline void dpy_gfx_resize(DisplayState *s)
{
struct DisplayChangeListener *dcl = s->listeners;
while (dcl != NULL) {
if (dcl->dpy_setdata) dcl->dpy_setdata(s);
dcl = dcl->next;
struct DisplayChangeListener *dcl;
QLIST_FOREACH(dcl, &s->listeners, next) {
if (dcl->dpy_gfx_resize) {
dcl->dpy_gfx_resize(s);
}
}
}
static inline void dpy_gfx_setdata(DisplayState *s)
{
struct DisplayChangeListener *dcl;
QLIST_FOREACH(dcl, &s->listeners, next) {
if (dcl->dpy_gfx_setdata) {
dcl->dpy_gfx_setdata(s);
}
}
}
static inline void dpy_refresh(DisplayState *s)
{
struct DisplayChangeListener *dcl = s->listeners;
while (dcl != NULL) {
if (dcl->dpy_refresh) dcl->dpy_refresh(s);
dcl = dcl->next;
struct DisplayChangeListener *dcl;
QLIST_FOREACH(dcl, &s->listeners, next) {
if (dcl->dpy_refresh) {
dcl->dpy_refresh(s);
}
}
}
static inline void dpy_copy(struct DisplayState *s, int src_x, int src_y,
int dst_x, int dst_y, int w, int h) {
struct DisplayChangeListener *dcl = s->listeners;
while (dcl != NULL) {
if (dcl->dpy_copy)
dcl->dpy_copy(s, src_x, src_y, dst_x, dst_y, w, h);
else /* TODO */
dcl->dpy_update(s, dst_x, dst_y, w, h);
dcl = dcl->next;
static inline void dpy_gfx_copy(struct DisplayState *s, int src_x, int src_y,
int dst_x, int dst_y, int w, int h)
{
struct DisplayChangeListener *dcl;
QLIST_FOREACH(dcl, &s->listeners, next) {
if (dcl->dpy_gfx_copy) {
dcl->dpy_gfx_copy(s, src_x, src_y, dst_x, dst_y, w, h);
} else { /* TODO */
dcl->dpy_gfx_update(s, dst_x, dst_y, w, h);
}
}
}
static inline void dpy_fill(struct DisplayState *s, int x, int y,
int w, int h, uint32_t c) {
struct DisplayChangeListener *dcl = s->listeners;
while (dcl != NULL) {
if (dcl->dpy_fill) dcl->dpy_fill(s, x, y, w, h, c);
dcl = dcl->next;
static inline void dpy_text_cursor(struct DisplayState *s, int x, int y)
{
struct DisplayChangeListener *dcl;
QLIST_FOREACH(dcl, &s->listeners, next) {
if (dcl->dpy_text_cursor) {
dcl->dpy_text_cursor(s, x, y);
}
}
}
static inline void dpy_cursor(struct DisplayState *s, int x, int y) {
struct DisplayChangeListener *dcl = s->listeners;
while (dcl != NULL) {
if (dcl->dpy_text_cursor) dcl->dpy_text_cursor(s, x, y);
dcl = dcl->next;
static inline void dpy_text_update(DisplayState *s, int x, int y, int w, int h)
{
struct DisplayChangeListener *dcl;
QLIST_FOREACH(dcl, &s->listeners, next) {
if (dcl->dpy_text_update) {
dcl->dpy_text_update(s, x, y, w, h);
}
}
}
static inline void dpy_text_resize(DisplayState *s, int w, int h)
{
struct DisplayChangeListener *dcl;
QLIST_FOREACH(dcl, &s->listeners, next) {
if (dcl->dpy_text_resize) {
dcl->dpy_text_resize(s, w, h);
}
}
}
static inline void dpy_mouse_set(struct DisplayState *s, int x, int y, int on)
{
struct DisplayChangeListener *dcl;
QLIST_FOREACH(dcl, &s->listeners, next) {
if (dcl->dpy_mouse_set) {
dcl->dpy_mouse_set(s, x, y, on);
}
}
}
static inline void dpy_cursor_define(struct DisplayState *s, QEMUCursor *cursor)
{
struct DisplayChangeListener *dcl;
QLIST_FOREACH(dcl, &s->listeners, next) {
if (dcl->dpy_cursor_define) {
dcl->dpy_cursor_define(s, cursor);
}
}
}
static inline bool dpy_cursor_define_supported(struct DisplayState *s)
{
struct DisplayChangeListener *dcl;
QLIST_FOREACH(dcl, &s->listeners, next) {
if (dcl->dpy_cursor_define) {
return true;
}
}
return false;
}
static inline int ds_get_linesize(DisplayState *ds)
{
return ds->surface->linesize;
return pixman_image_get_stride(ds->surface->image);
}
static inline uint8_t* ds_get_data(DisplayState *ds)
{
return ds->surface->data;
return (void *)pixman_image_get_data(ds->surface->image);
}
static inline int ds_get_width(DisplayState *ds)
{
return ds->surface->width;
return pixman_image_get_width(ds->surface->image);
}
static inline int ds_get_height(DisplayState *ds)
{
return ds->surface->height;
return pixman_image_get_height(ds->surface->image);
}
static inline int ds_get_bits_per_pixel(DisplayState *ds)
{
return ds->surface->pf.bits_per_pixel;
int bits = PIXMAN_FORMAT_BPP(ds->surface->format);
return bits;
}
static inline int ds_get_bytes_per_pixel(DisplayState *ds)
{
return ds->surface->pf.bytes_per_pixel;
int bits = PIXMAN_FORMAT_BPP(ds->surface->format);
return (bits + 7) / 8;
}
static inline pixman_format_code_t ds_get_format(DisplayState *ds)
{
return ds->surface->format;
}
#ifdef CONFIG_CURSES
+2 -2
View File
@@ -921,8 +921,8 @@ static void blizzard_update_display(void *opaque)
for (; y < s->my[1]; y ++, src += bypl, dst += bypl)
memcpy(dst, src, bwidth);
dpy_update(s->state, s->mx[0], s->my[0],
s->mx[1] - s->mx[0], y - s->my[0]);
dpy_gfx_update(s->state, s->mx[0], s->my[0],
s->mx[1] - s->mx[0], y - s->my[0]);
s->mx[0] = s->x;
s->mx[1] = 0;
+1 -1
View File
@@ -1307,7 +1307,7 @@ static void exynos4210_fimd_update(void *opaque)
fimd_copy_line_toqemu(global_width, s->ifb + global_width * line *
RGBA_SIZE, d + global_width * line * bpp);
}
dpy_update(s->console, 0, 0, global_width, global_height);
dpy_gfx_update(s->console, 0, 0, global_width, global_height);
}
s->invalidate = false;
s->vidintcon[1] |= FIMD_VIDINT_INTFRMPEND;
+4 -3
View File
@@ -197,7 +197,8 @@ static void g364fb_draw_graphic8(G364State *s)
reset_dirty(s, page_min, page_max);
page_min = (ram_addr_t)-1;
page_max = 0;
dpy_update(s->ds, xmin, ymin, xmax - xmin + 1, ymax - ymin + 1);
dpy_gfx_update(s->ds, xmin, ymin,
xmax - xmin + 1, ymax - ymin + 1);
xmin = s->width;
xmax = 0;
ymin = s->height;
@@ -216,7 +217,7 @@ static void g364fb_draw_graphic8(G364State *s)
done:
if (page_min != (ram_addr_t)-1) {
dpy_update(s->ds, xmin, ymin, xmax - xmin + 1, ymax - ymin + 1);
dpy_gfx_update(s->ds, xmin, ymin, xmax - xmin + 1, ymax - ymin + 1);
reset_dirty(s, page_min, page_max);
}
}
@@ -238,7 +239,7 @@ static void g364fb_draw_blank(G364State *s)
d += ds_get_linesize(s->ds);
}
dpy_update(s->ds, 0, 0, s->width, s->height);
dpy_gfx_update(s->ds, 0, 0, s->width, s->height);
s->blanked = 1;
}
+3 -3
View File
@@ -196,7 +196,7 @@ static void jazz_led_update_display(void *opaque)
}
s->state = REDRAW_NONE;
dpy_update(ds, 0, 0, ds_get_width(ds), ds_get_height(ds));
dpy_gfx_update(ds, 0, 0, ds_get_width(ds), ds_get_height(ds));
}
static void jazz_led_invalidate_display(void *opaque)
@@ -210,7 +210,7 @@ static void jazz_led_text_update(void *opaque, console_ch_t *chardata)
LedState *s = opaque;
char buf[2];
dpy_cursor(s->ds, -1, -1);
dpy_text_cursor(s->ds, -1, -1);
qemu_console_resize(s->ds, 2, 1);
/* TODO: draw the segments */
@@ -218,7 +218,7 @@ static void jazz_led_text_update(void *opaque, console_ch_t *chardata)
console_write_ch(chardata++, 0x00200100 | buf[0]);
console_write_ch(chardata++, 0x00200100 | buf[1]);
dpy_update(s->ds, 0, 0, 2, 1);
dpy_text_update(s->ds, 0, 0, 2, 1);
}
static int jazz_led_post_load(void *opaque, int version_id)
+1 -1
View File
@@ -134,7 +134,7 @@ static void vgafb_update_display(void *opaque)
&first, &last);
if (first >= 0) {
dpy_update(s->ds, 0, first, s->regs[R_HRES], last - first + 1);
dpy_gfx_update(s->ds, 0, first, s->regs[R_HRES], last - first + 1);
}
s->invalidate = 0;
}
+1 -1
View File
@@ -526,7 +526,7 @@ static void lcd_refresh(void *opaque)
ds_get_bits_per_pixel(s->ds));
}
dpy_update(s->ds, 0, 0, 128*3, 64*3);
dpy_gfx_update(s->ds, 0, 0, 128*3, 64*3);
}
static void lcd_invalidate(void *opaque)
+1 -1
View File
@@ -1375,7 +1375,7 @@ static void n8x0_init(QEMUMachineInitArgs *args,
size until the guest activates the display. */
ds = get_displaystate();
ds->surface = qemu_resize_displaysurface(ds, 800, 480);
dpy_resize(ds);
dpy_gfx_resize(ds);
}
static struct arm_boot_info n800_binfo = {
+1 -1
View File
@@ -219,7 +219,7 @@ static void omap_update_display(void *opaque)
draw_line, omap_lcd->palette,
&first, &last);
if (first >= 0) {
dpy_update(omap_lcd->state, 0, first, width, last - first + 1);
dpy_gfx_update(omap_lcd->state, 0, first, width, last - first + 1);
}
omap_lcd->invalidate = 0;
}
+1 -1
View File
@@ -273,7 +273,7 @@ static void palmte_init(QEMUMachineInitArgs *args)
will set the size once configured, so this just sets an initial
size until the guest activates the display. */
ds->surface = qemu_resize_displaysurface(ds, 320, 320);
dpy_resize(ds);
dpy_gfx_resize(ds);
}
static QEMUMachine palmte_machine = {
+1 -1
View File
@@ -239,7 +239,7 @@ static void pl110_update_display(void *opaque)
fn, s->palette,
&first, &last);
if (first >= 0) {
dpy_update(s->ds, 0, first, s->cols, last - first + 1);
dpy_gfx_update(s->ds, 0, first, s->cols, last - first + 1);
}
s->invalidate = 0;
}
+4 -4
View File
@@ -871,20 +871,20 @@ static void pxa2xx_update_display(void *opaque)
if (miny >= 0) {
switch (s->orientation) {
case 0:
dpy_update(s->ds, 0, miny, s->xres, maxy - miny + 1);
dpy_gfx_update(s->ds, 0, miny, s->xres, maxy - miny + 1);
break;
case 90:
dpy_update(s->ds, miny, 0, maxy - miny + 1, s->xres);
dpy_gfx_update(s->ds, miny, 0, maxy - miny + 1, s->xres);
break;
case 180:
maxy = s->yres - maxy - 1;
miny = s->yres - miny - 1;
dpy_update(s->ds, 0, maxy, s->xres, miny - maxy + 1);
dpy_gfx_update(s->ds, 0, maxy, s->xres, miny - maxy + 1);
break;
case 270:
maxy = s->yres - maxy - 1;
miny = s->yres - miny - 1;
dpy_update(s->ds, maxy, 0, miny - maxy + 1, s->xres);
dpy_gfx_update(s->ds, maxy, 0, miny - maxy + 1, s->xres);
break;
}
}
+7 -7
View File
@@ -24,7 +24,7 @@
static void qxl_blit(PCIQXLDevice *qxl, QXLRect *rect)
{
uint8_t *src;
uint8_t *dst = qxl->vga.ds->surface->data;
uint8_t *dst = ds_get_data(qxl->vga.ds);
int len, i;
if (is_buffer_shared(qxl->vga.ds->surface)) {
@@ -123,17 +123,17 @@ static void qxl_render_update_area_unlocked(PCIQXLDevice *qxl)
qxl->guest_primary.surface.width,
qxl->guest_primary.surface.height);
}
dpy_resize(vga->ds);
dpy_gfx_resize(vga->ds);
}
for (i = 0; i < qxl->num_dirty_rects; i++) {
if (qemu_spice_rect_is_empty(qxl->dirty+i)) {
break;
}
qxl_blit(qxl, qxl->dirty+i);
dpy_update(vga->ds,
qxl->dirty[i].left, qxl->dirty[i].top,
qxl->dirty[i].right - qxl->dirty[i].left,
qxl->dirty[i].bottom - qxl->dirty[i].top);
dpy_gfx_update(vga->ds,
qxl->dirty[i].left, qxl->dirty[i].top,
qxl->dirty[i].right - qxl->dirty[i].left,
qxl->dirty[i].bottom - qxl->dirty[i].top);
}
qxl->num_dirty_rects = 0;
}
@@ -234,7 +234,7 @@ int qxl_render_cursor(PCIQXLDevice *qxl, QXLCommandExt *ext)
return 1;
}
if (!qxl->ssd.ds->mouse_set || !qxl->ssd.ds->cursor_define) {
if (!dpy_cursor_define_supported(qxl->ssd.ds)) {
return 0;
}
+2 -2
View File
@@ -1864,8 +1864,8 @@ static void display_refresh(struct DisplayState *ds)
}
static DisplayChangeListener display_listener = {
.dpy_update = display_update,
.dpy_resize = display_resize,
.dpy_gfx_update = display_update,
.dpy_gfx_resize = display_resize,
.dpy_refresh = display_refresh,
};
+2 -2
View File
@@ -1351,7 +1351,7 @@ static void sm501_draw_crt(SM501State * s)
} else {
if (y_start >= 0) {
/* flush to display */
dpy_update(s->ds, 0, y_start, width, y - y_start);
dpy_gfx_update(s->ds, 0, y_start, width, y - y_start);
y_start = -1;
}
}
@@ -1362,7 +1362,7 @@ static void sm501_draw_crt(SM501State * s)
/* complete flush to display */
if (y_start >= 0)
dpy_update(s->ds, 0, y_start, width, y - y_start);
dpy_gfx_update(s->ds, 0, y_start, width, y - y_start);
/* clear dirty flags */
if (page_min != ~0l) {

Some files were not shown because too many files have changed in this diff Show More