Re: Weird Problem With CGImage
Re: Weird Problem With CGImage
- Subject: Re: Weird Problem With CGImage
- From: "Adam R. Maxwell" <email@hidden>
- Date: Fri, 25 Apr 2008 09:10:57 -0700
On Friday, April 25, 2008, at 08:58AM, "Jean-Daniel Dupas" <email@hidden> wrote:
>
>Using CGImageRef is not a realiable way to access pixel data of an
>image.
>You should create a CGBitmapContextCreate() instead and draw the part
>you want in this context.
>
>http://developer.apple.com/qa/qa2007/qa1509.html
That document predates the publication of CGDataProviderCopyData in the API, though, which should provide a reliable way to access pixel data. In this particular case, it looks like drawing to a new bitmap context would be a more direct route, as you said. However, I'm using CGDataProviderCopyData myself, and I'd like to know where it can fail like this; it WFM so far.
--
adam
_______________________________________________
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