Instance Method

pointForCaptureDevicePointOfInterest:

Converts a point from the coordinate space of the capture device to the coordinate space of the layer.

Declaration

- (CGPoint)pointForCaptureDevicePointOfInterest:(CGPoint)captureDevicePointOfInterest;

Parameters

captureDevicePointOfInterest

A scalar point whose coordinates are relative to the coordinate system of the capture device that is providing input to the layer. The coordinates in this point must be in the range 0.0 to 1.0, where the point (0.0, 0.0) corresponds to the top left corner of the unrotated picture and the point (1.0, 1.0) represents the bottom right corner of the unrotated picture.

Return Value

A point in the coordinate system of this layer object. The coordinates of this point represent pixel values.

Discussion

The conversion performed by this method takes the layer’s frame size and its videoGravity into consideration.

See Also

Converting Between Coordinate Systems

- captureDevicePointOfInterestForPoint:

Converts a point from layer coordinates to the coordinate space of the capture device.

- rectForMetadataOutputRectOfInterest:

Converts a rectangle in the coordinate system used for metadata outputs to one in the preview layer’s coordinate system.

- metadataOutputRectOfInterestForRect:

Converts a rectangle in the preview layer’s coordinate system to one in the coordinate system used for metadata outputs.

- transformedMetadataObjectForMetadataObject:

Converts a metadata object’s visual properties to layer coordinates.