Theocacao
Leopard
Design Element
Comment on "Convert an NSImage to CIImage"
by Petteri Kamppuri — Nov 14
Actually, there's a much shorter (measuring lines of code) and "more supported" (meaning there's an API) way:

+(NSImage *) imageFromCIImage:(CIImage *)ciImage
{
NSImage *image = [[[NSImage alloc] initWithSize:NSMakeSize([ciImage extent].size.width, [ciImage extent].size.height)] autorelease];

[image addRepresentation:[NSCIImageRep imageRepWithCIImage:ciImage]];

return image;
}
Back to "Convert an NSImage to CIImage"
Design Element

Copyright © Scott Stevenson 2004-2015