qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Alexander Graf <alex@csgraf.de>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [patch] cocoa.m - Core Graphics support
Date: Thu, 31 Jan 2008 09:29:02 +0100	[thread overview]
Message-ID: <B7FD213C-E0DF-4FF5-9E61-419EF73448EC@csgraf.de> (raw)
In-Reply-To: <40275543-3906-421D-B6DB-13B1BA72E35B@kberg.ch>


On Jan 30, 2008, at 9:30 PM, Mike Kronenberg wrote:

>
> On 30.01.2008, at 19:59, Alexander Graf wrote:
>
>>
>> On Jan 21, 2008, at 5:18 PM, Mike Kronenberg wrote:
>>
>>> This is a complete rewrite of cocoa.m to support Core Graphics.
>>>
>>> As mentioned in earlier threads, the QuickDraw API is depreciated  
>>> starting with OS X 10.4.
>>> Now with OS X 10.5 it won't even compile QuickDraw code on x86_64.
>>>
>>>
>>> This implementation of cocoa.m has the following features:
>>>
>>> [new] partial drawing of the window as needed, implemented with CG.
>>> [new] fullscreen support
>>> [new] tablet support
>>> [new] View menu and item to enter Fullscreen (cmd-f)
>>> [new] Help menu and items to show qemu-doc.html (cmd-?) and qemu- 
>>> tec.html in the OS X "Help Viewer"
>>> [new] -name is shown in Title-bar of window
>>> [fix] Application menu creation for 10.4+ (API is private as of  
>>> 10.4)
>>> [fix] Mouse-clicks on the guests window widgets are no longer  
>>> intercepted
>>> [fix] apple keyboard shortcuts forwarded (minimize (cmd-m), hide  
>>> QEMU (cmd-h), quit QEMU (cmd-q))
>>>
>>> It should compile on ppc/intel starting form 10.3 (10.2 with the  
>>> known workarounds).
>>>
>>> Please test and comment
>>
>> I'm sorry that I didn't find the time to test this implementation  
>> before.
>>
>> It's damn slow.
>>
>> I ran it using my x86_64 on 10.5.1, targetting x86_64-softmmu and  
>> booting a linux kernel. I could literally see every like getting  
>> repainted (which btw did not happen with my quick hacky version I  
>> sent to the list some time ago).
>>
>> I think the major problem is that too much is being done during  
>> drawRect. If I understand the code correctly, you create CGImage  
>> objects on every repaint, which is prone to be slow.
>>
>> Why not simply reuse the framebuffer qemu provides anyway and leave  
>> everything else to CG?
>>
>> Alex
>>
>>
>
>
> Hi Alex,
>
> yes, as stated earlyer, it is slower than Quickdraw, especially if  
> the whole screen is redrawn. Overal emulation speed for GUI apps is  
> faster, dough, as only small portions of the screen are redrawn.

That's good to hear. I tend to use Linux in command line mode in qemu  
quite often though, so for me the most important thing is full screen  
update, which apparently became slower. Merely running an SDL targeted  
qemu (did this on x86_64 linux) vs a cocoa one shows that something  
feels wrong on cocoa. Maybe there is no other way around this, but I  
still don't like seeing the screen scroll line for line ;-).

Unfortunately I don't have the time right now to investigate this in  
detail and I am really not into graphics programming usually. So for  
the time being it is still _way_ better than a solution that doesn't  
even compile.

The one thing I want to stress here is that maybe it might be worth  
looking into alternatives. If I find the time to do it, I will do so.  
I somehow like the idea of having a GL based video output.

Alex

  parent reply	other threads:[~2008-01-31  8:29 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-01-21 16:18 [Qemu-devel] [patch] cocoa.m - Core Graphics support Mike Kronenberg
2008-01-30 18:59 ` Alexander Graf
2008-01-30 19:05   ` Alexander Graf
2008-01-30 20:30   ` Mike Kronenberg
2008-01-30 20:39     ` Johannes Schindelin
2008-01-30 21:18       ` andrzej zaborowski
2008-01-31  9:15         ` Jamie Lokier
2008-01-30 21:00     ` Pierre d'Herbemont
2008-01-30 21:54     ` Anthony Liguori
2008-01-31  9:46       ` Jamie Lokier
2008-01-31 11:38         ` Julian Seward
2008-01-31 22:40         ` Anthony Liguori
2008-01-31 23:03           ` Jamie Lokier
2008-01-31  8:29     ` Alexander Graf [this message]
2008-01-30 20:44   ` Mike Kronenberg

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=B7FD213C-E0DF-4FF5-9E61-419EF73448EC@csgraf.de \
    --to=alex@csgraf.de \
    --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).