1
我有一個CGContext,並試圖在上面繪製圖像。 我有一個NSImage *負載,我用其他方法。如何使用CGContext在OSX上繪製圖像
NSImage *check = [[NSImage alloc] initWithContentsOfFile:@"check.icns"];
CGContextDrawImage(arg2, CGRectMake(0, 0, 145, 15), check);
但CGContext想要一個CGImage *我該如何使用我的NSImage *?
感謝
[將NSImage *轉換爲CGImageRef?](http://stackoverflow.com/questions/2548059/turning-an-nsimage-into-a-cgimageref) – trojanfoe