Instance Method

initWithTargetedCGImage:orientation:options:completionHandler:

Creates a new request targeting a Core Graphics image of known orientation, executing the completion handler when done.

Declaration

- (instancetype)initWithTargetedCGImage:(CGImageRef)cgImage orientation:(CGImagePropertyOrientation)orientation options:(NSDictionary<VNImageOption, id> *)options completionHandler:(VNRequestCompletionHandler)completionHandler;

Parameters

cgImage

The targeted Core Graphics image.

orientation

The orientation of the image buffer, based on EXIF specification and superseding other orientation information. The value must be an integer from 1 to 8; see kCGImagePropertyOrientation for details.

options

A dictionary with options specifying auxiliary information for the image.

completionHandler

The block to invoke when the request has finished executing.

See Also

Initializing a Targeted Image Request

- initWithTargetedCGImage:options:

Creates a new request targeting a Core Graphics image.

- initWithTargetedCGImage:options:completionHandler:

Creates a new request targeting a Core Graphics image, executing the completion handler when done.

- initWithTargetedCGImage:orientation:options:

Creates a new request targeting a Core Graphics image of known orientation.

- initWithTargetedCIImage:options:

Creates a new request targeting a CIImage.

- initWithTargetedCIImage:options:completionHandler:

Creates a new request targeting a CIImage, executing the completion handler when done.

- initWithTargetedCIImage:orientation:options:

Creates a new request targeting a CIImage of known orientation.

- initWithTargetedCIImage:orientation:options:completionHandler:

Creates a new request targeting a CIImage of known orientation, executing the completion handler when done.

- initWithTargetedCVPixelBuffer:options:

Creates a new request targeting an image in a CVPixelBufferRef.

- initWithTargetedCVPixelBuffer:options:completionHandler:

Creates a new request targeting an image in a CVPixelBufferRef, executing the completion handler when done.

- initWithTargetedCVPixelBuffer:orientation:options:

Creates a new request targeting an image in a CVPixelBufferRef of known orientation.

- initWithTargetedCVPixelBuffer:orientation:options:completionHandler:

Creates a new request targeting an image in a CVPixelBufferRef of known orientation, executing the completion handler when done.

- initWithTargetedImageData:options:

Creates a new request targeting an image as raw data.

- initWithTargetedImageData:options:completionHandler:

Creates a new request targeting an image as raw data, executing the completion handler when done.

- initWithTargetedImageData:orientation:options:

Creates a new request targeting a raw data image of known orientation.

- initWithTargetedImageData:orientation:options:completionHandler:

Creates a new request targeting a raw data image of known orientation, executing the completion handler when done.

- initWithTargetedImageURL:options:

Creates a new request targeting an image at the specified URL.

- initWithTargetedImageURL:options:completionHandler:

Creates a new request targeting an image at the specified URL, executing the completion handler when done.

- initWithTargetedImageURL:orientation:options:

Creates a new request targeting an image of known orientation, at the specified URL.

- initWithTargetedImageURL:orientation:options:completionHandler:

Creates a new request targeting an image of known orientation, at the specified URL, executing the completion handler when done.