Drawing an NSImage into a GWorld
Drawing an NSImage into a GWorld
- Subject: Drawing an NSImage into a GWorld
- From: Darrin Cardani <email@hidden>
- Date: Tue, 12 Jul 2005 10:04:23 -0500
I'm working on an iMovie plugin. In iMovie, you have to return the
final rendered frame as a GWorld. However, I have an NSImage (which
is known to have an NSBitmapImageRep) that I need to draw into that
GWorld. What's the easiest way to do that?
I realize I could convert the NSImage into a CGImageRef and wrap a
CGBitmapContext around the GWorld, then draw the CGImageRef into
that, but that seems rather roundabout.
I could also get the bitmap representation's raw pixel data into
another GWorld and use CopyBits to get it into the final (differently
sized) GWorld. But I'm wondering if there's a recommended way to do
it?
Thanks,
Darrin
--
Darrin Cardani - email@hidden
President, Buena Software, Inc.
<http://www.buena.com/>
Video, Image and Audio Processing Development
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden