31 |
31 |
return;
|
32 |
32 |
}
|
33 |
33 |
if (!qxl->guest_primary.data) {
|
34 |
|
dprint(qxl, 1, "%s: initializing guest_primary.data\n", __func__);
|
|
34 |
trace_qxl_render_blit_guest_primary_initialized();
|
35 |
35 |
qxl->guest_primary.data = memory_region_get_ram_ptr(&qxl->vga.vram);
|
36 |
36 |
}
|
37 |
|
dprint(qxl, 2, "%s: stride %d, [%d, %d, %d, %d]\n", __func__,
|
38 |
|
qxl->guest_primary.qxl_stride,
|
|
37 |
trace_qxl_render_blit(qxl->guest_primary.qxl_stride,
|
39 |
38 |
rect->left, rect->right, rect->top, rect->bottom);
|
40 |
39 |
src = qxl->guest_primary.data;
|
41 |
40 |
if (qxl->guest_primary.qxl_stride < 0) {
|
... | ... | |
107 |
106 |
qxl->guest_primary.data = memory_region_get_ram_ptr(&qxl->vga.vram);
|
108 |
107 |
qxl_set_rect_to_surface(qxl, &qxl->dirty[0]);
|
109 |
108 |
qxl->num_dirty_rects = 1;
|
110 |
|
dprint(qxl, 1, "%s: %dx%d, stride %d, bpp %d, depth %d\n",
|
111 |
|
__FUNCTION__,
|
|
109 |
trace_qxl_render_guest_primary_resized(
|
112 |
110 |
qxl->guest_primary.surface.width,
|
113 |
111 |
qxl->guest_primary.surface.height,
|
114 |
112 |
qxl->guest_primary.qxl_stride,
|
... | ... | |
118 |
116 |
if (surface->width != qxl->guest_primary.surface.width ||
|
119 |
117 |
surface->height != qxl->guest_primary.surface.height) {
|
120 |
118 |
if (qxl->guest_primary.qxl_stride > 0) {
|
121 |
|
dprint(qxl, 1, "%s: using guest_primary for displaysurface\n",
|
122 |
|
__func__);
|
123 |
119 |
qemu_free_displaysurface(vga->ds);
|
124 |
120 |
qemu_create_displaysurface_from(qxl->guest_primary.surface.width,
|
125 |
121 |
qxl->guest_primary.surface.height,
|
... | ... | |
127 |
123 |
qxl->guest_primary.abs_stride,
|
128 |
124 |
qxl->guest_primary.data);
|
129 |
125 |
} else {
|
130 |
|
dprint(qxl, 1, "%s: resizing displaysurface to guest_primary\n",
|
131 |
|
__func__);
|
132 |
126 |
qemu_resize_displaysurface(vga->ds,
|
133 |
127 |
qxl->guest_primary.surface.width,
|
134 |
128 |
qxl->guest_primary.surface.height);
|
... | ... | |
187 |
181 |
void qxl_render_update_area_done(PCIQXLDevice *qxl, QXLCookie *cookie)
|
188 |
182 |
{
|
189 |
183 |
qemu_mutex_lock(&qxl->ssd.lock);
|
|
184 |
trace_qxl_render_update_area_done(cookie);
|
190 |
185 |
qemu_bh_schedule(qxl->update_area_bh);
|
191 |
186 |
qxl->render_update_cookie_num--;
|
192 |
187 |
qemu_mutex_unlock(&qxl->ssd.lock);
|