Function VNNormalizedRectForImageRectUsingRegionOfInterest

Source
pub unsafe extern "C-unwind" fn VNNormalizedRectForImageRectUsingRegionOfInterest(
    image_rect: CGRect,
    image_width: usize,
    image_height: usize,
    roi: CGRect,
) -> CGRect
Available on crate features VNUtils and objc2-core-foundation only.
Expand description

Returns an image rectangle in normalized coordinates in relation to the region of interest.

Parameter imageRect: The rectangle in image coordinate space.

Parameter imageWidth: The pixel width of the image.

Parameter imageHeight: The pixel height of the image.

Parameter roi: The region of interest on which the normalized rect will be based on.

Returns: the normalized rectangle in relation to the region of interest.