macOS/iOS API解説

iOS , Mac アプリケーション開発のために使われる主要フレームワークの日本語情報です。2010年代に書かれた内容です。今後更新はありません。

目次

createCGImage:fromRect:

CIImageと矩形でCGImageを返します
-(CGImageRef)createCGImage:(CIImage *)im:
            fromRect:(CGRect)r:

解説

CIImageと矩形でCGImageを返します。

返り値

( CGImageRef )

なし

引数

( CIImage * )im
( CGRect )r

クラス

CIContext

Instance Methods

使用可能

10.4

参照

例文

CIContext*		ciContext = [CIContext contextWithCGContext:(CGContextRef)[[NSGraphicsContext currentContext] graphicsPort] options:nil];
				//宛先矩形を計算
				CGRect	imageBounds = [image extent];
				CGImageRef		testImageRef = [ciContext createCGImage:inputImage fromRect:imageBounds];
				printf("-------------------------------------\n");
				CFShow(testImageRef);
				printf("-------------------------------------\n");