Re: Quick question: easy way to draw bitmap?
Re: Quick question: easy way to draw bitmap?
- Subject: Re: Quick question: easy way to draw bitmap?
- From: Scott Anguish <email@hidden>
- Date: Fri, 13 Jul 2007 04:20:26 -0400
On Jul 13, 2007, at 2:53 AM, Jeff Bland wrote:
Ah,
initWithBitmapDataPlanes:pixelsWide:pixelsHigh:bitsPerSample:samplesPerPixel
:
hasAlpha:isPlanar:colorSpaceName:bytesPerRow:bitsPerPixel:
looks like what I need. And it looks like it will point to my data
(rather
than copying the bitmap data to its own buffer). My bitmp data
however is
being constantly updated (animated), so how do I tell the
view/image/imagerep that the data has been updated and it needs to
redraw?
update the data
call setNeedsDisplay: on the view that is displaying it.
of course this general approach (loading the data the way you are,
etc..) may not be the best way, depending on where your data is coming
from, the format it's in, colorspace, how you update the data, how
often you update the data, etc..
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden