From: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH] Update cocoa.m to match new DisplayState code
Date: Mon, 26 Jan 2009 11:14:29 +0000 [thread overview]
Message-ID: <497D9B15.10900@eu.citrix.com> (raw)
In-Reply-To: <1EA45CC4-0126-4CCC-B467-E528511C1E07@digitalescape.info>
Samuel Benson wrote:
>> It would be better not to change the DisplayState surface from
>> cocoa\sdl\vnc but try to render the format exposed by the emulated
>> graphic card ourself.
>> In fact in most cases the emulated vga exposes a 32bpp surface with
>> linesize = width * 4, so you don't need to force it yourself.
>> The only exception is the 16bpp case, but you should be able to render
>> that as well without too many problems.
>
> The previous code forced this change, and as this code merely synced it
> to the new structures,
> I did not think anything to be wrong with it. If the structures come pre
> initialized,
> I'll remove these lines and see if it still works.
The old DisplayState interface was supposed to be initialized by cocoa,
then the emulated graphic card would do the conversion into the format
requested by cocoa.
The new DisplayState interface is initialized by the graphic card and
cocoa is supposed to be able to render whatever format is exposed by the
graphic card. The pixel formats actually exposed are very few, see my
other mail.
But from the second version of the patch I gather that you already
understand how the new interface works.
> The one section I did have trouble understanding was the DisplaySurface
> flags; are those set
> in regards to the host endianness or the guests?
>
QEMU_BIG_ENDIAN_FLAG refers to the host endianness.
The guest video buffer is automatically converted into the host
endianness if necessary, so you don't have to worry about it.
You can always assume that the DisplayState surface has the same
endianness as the host, as long as you repect the pixelformat
ds->surface->pf (see my other mail and console.c:qemu_default_pixelformat).
next prev parent reply other threads:[~2009-01-26 19:06 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-01-23 22:41 [Qemu-devel] [PATCH] Update cocoa.m to match new DisplayState code Samuel Benson
2009-01-24 15:36 ` Stefano Stabellini
2009-01-24 19:16 ` Samuel Benson
2009-01-24 21:22 ` Alexander Graf
2009-01-25 6:34 ` Samuel Benson
2009-01-26 11:14 ` Stefano Stabellini [this message]
2009-01-24 17:41 ` Anthony Liguori
[not found] ` <1A55CC66-7DBD-4129-9FAE-C5FD6F3D2FC2@hotmail.com>
2009-01-25 21:14 ` C.W. Betts
2009-01-25 21:48 ` Samuel Benson
-- strict thread matches above, loose matches on Subject: below --
2009-01-25 12:25 Christian Brunschen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=497D9B15.10900@eu.citrix.com \
--to=stefano.stabellini@eu.citrix.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).