Instance Method

imageWithActions:

Creates an image by following a set of drawing instructions.

Declaration

- (UIImage *)imageWithActions:(UIGraphicsImageDrawingActions)actions;

Parameters

actions

A UIGraphicsImageDrawingActions block that, when invoked by the renderer, executes a set of drawing instructions to create the output image.

Return Value

A UIImage object created by the supplied drawing actions.

Discussion

You provide a set of drawing instructions as the block argument to this method, and the method will return the resultant UIImage object.

You can call this method repeatedly to create multiple images, each of which has identical dimensions and format.

See Also

Creating Images

- JPEGDataWithCompressionQuality:actions:

Creates a JPEG-encoded image by following a set of drawing instructions.

- PNGDataWithActions:

Creates a PNG-encoded image by following a set of drawing instructions.