[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH] use corect depth from DisplaySurface in vmware

From: andrzej zaborowski
Subject: Re: [Qemu-devel] [PATCH] use corect depth from DisplaySurface in vmware_vga.c
Date: Sun, 23 Aug 2009 19:25:32 +0200

2009/8/17 Reimar Döffinger <address@hidden>:
> Hello,
> for what I can tell, there is no way for vmware_vga to work correctly
> right now. It assumes that the framebuffer bits-per-pixel and the one
> from the DisplaySurface are identical (it uses directly the VRAM from
> vga.c), but it always assumes 3 bytes per pixel, which is never possible
> with the current version of DisplaySurface.
> Attached patch fixes that by using ds_get_bits_per_pixel.

It was discussed at some point earlier that at the time this code runs
SDL is not initialised and the depth returned is an arbitrary value
from default allocator.  What vmware_vga really should do is ask SDL
for the host's depth and set the surface's pixelformat to that.
Unfortunately the ability to know host's pixel depth was dropped
during video API conversion and afaik hasn't been added till now.  The
also arbitrary value of 24 bits was stuffed there for some reason but
it seems to work for me.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]