Getting CGContext for a window
I'm trying to get a CGContext for a window, so I can dump it to a PNG CGImage and take a screenshot/movie.
I can't seem to find any method that gets me a CGContextRef in Carbon other than the Printing Manager functions, and those seem inappropriate for my needs (I have to set up a printing session first). Does one exist? I can't seem to find it in the Quartz2D reference guide (only the Printing Manager functions are listed).
I know in Cocoa there's a message, graphicsContext, for it.
Is there a better way to take a screenshot/sequence of screenshots from a given WindowRef?
I can't seem to find any method that gets me a CGContextRef in Carbon other than the Printing Manager functions, and those seem inappropriate for my needs (I have to set up a printing session first). Does one exist? I can't seem to find it in the Quartz2D reference guide (only the Printing Manager functions are listed).
I know in Cocoa there's a message, graphicsContext, for it.
Is there a better way to take a screenshot/sequence of screenshots from a given WindowRef?
Newest game: Glow, a sci-fi RPG with lots of zombie bashing. Get it: OS X
http://developer.apple.com/documentation...lementID_4
Doesn't look very helpful, actually :|
I'd guess that this will be a very slow way to do what you want, anyway... not that I can think of a better one that doesn't snapshot the whole screen...
Doesn't look very helpful, actually :|
I'd guess that this will be a very slow way to do what you want, anyway... not that I can think of a better one that doesn't snapshot the whole screen...

