On 31 Dec 2009, at 22:26, David Blanton wrote:

> Given an array of color data (a generic bitmap) what is the best / fastest / 
> recommended method to convert this to an NSImage?

Strictly speaking, the quickest way to generate an NSImage object would be to 
create an NSImageRep that knows how to draw your array of color data. Then, 
create an NSImage with that. The ways to do that:

A) Can you directly init an NSBitmapImageRep from the data? If so, use that

B) Create a NSCustomImageRep object and have the existing holder of the image 
data implement the drawing methods.

C) Create your own NSImageRep 
subclass._______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to