NSBitmap object created from a Core Graphics image object.
- macOS 10.5+
A Core Graphics image object (an opaque type) from which to create the receiver. This opaque type is retained.
NSBitmap object initialized from the contents of the Core Graphics image.
If you use this method, you should treat the resulting bitmap
NSBitmap object as read only. Because it only retains the value in the
cg parameter, rather than unpacking the data, accessing the pixel data requires the creation of a copy of that data in memory. Changes to that data are not saved back to the Core Graphics image.