Since these functions are deprecated, it is a good idea to replace
them with a modern stuff.
I would substitute GetPicture with this:
- read the content of the resource into a CFDataRef
- create a CGImageSourceRef from that data (probably, it would be
wise to set kCGImageSourceTypeIdentifierHint to CFSTR
("public.image") or even CFSTR("com.apple.pict"))
- get a CGImage from it
- don't forget to release all these guys
Since PICT can contain vector image data it's probably better to
use the PICT support in Quartz. You have to create a standard
CoreGraphics data provider that refers to your PICT data, then use
QDPictCreateWithProvider and QDPictDrawToCGContext.
That's true, but you should monitor the process closely.
Quartz and QuickDraw use very different imaging models and these two
routines do not generate pixel-for-pixel renditions of the PICT
data. As a result, you can get objectionable artifacts from using
them. Converting the PICTs to JPEG or PNG may be important if the
integrity of the image is important. (but as Nick implies... you
would loose the "vector-like" nature of the metafile)
Scott
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Quartz-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden