Re: [OT] Bitmaps for controls
Re: [OT] Bitmaps for controls
- Subject: Re: [OT] Bitmaps for controls
- From: Urs Heckmann <email@hidden>
- Date: Wed, 16 Oct 2002 13:17:39 +0200
Hi Art,
as far as I can see, when you use the VSTGUI-approach, you don't need
doublebuffering and no offscreen graphics world. In (standard) VSTGUI
all bitmaps are always "final" and do not need compositing. (Even
VU-meters can be drawn directly without flickering)
However, if you have something generic that needs to draw on a bitmap
(envelopes the like), I have made quite some good experience with CG
drawing (thanks to your help :-)
I don't know where I read it, but it is stated somewhere that Quartz
will automatically take over the doublebuffering for you regardless if
you use CG or QuickDraw. So it might be a wasted effort to draw in a
GWorld first and then copy that to the windowport.
I think it is this way: Your controls draw driven by a draw-event, and
after successful return the windowmanager will update the control's
region. I don't doublebuffer and there's no flickering at all.
Cheers,
;) Urs
Am Mittwoch, 16.10.02, um 12:42 Uhr (Europe/Berlin) schrieb Art
Gillespie:
Hi all,
For obvious reasons, I'm working on a VSTGUI drop-in replacement...
when it comes to dealing with bitmaps I'm loading a PICT resource and
drawing it into a offscreen graphics world, and then using CopyBits on
the graphics world's PixelMap to get segments of the bitmap onto the
screen.
Now, my question is this: is keeping the offscreen graphics world
around the right way to cache the bitmap in Mac-Land? This is how I'm
doing it now, and it works great, but it seems a bit heavyweight.
However, my efforts to copy the PixelMap and then dispose the graphics
world results in weird graphics and/or crashes on subsequent calls to
CopyBits.
If anyone can point me to 'best-practice' resources on this kind of
low-level graphics asset management in QuickDraw I'd be much
appreciative.
Thanks,
Art
>>0xBA
_______________________________________________
coreaudio-api mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/coreaudio-api
Do not post admin requests to the list. They will be ignored.