CaptureImage.cropCenter Method¶
Module: CaptureImage
Definition¶
Crops the image at its center with the specified aspect ratio.
The function computes the largest crop that fits within the input image while maintaining
the target aspect ratio. The crop is centered in the original image.
CaptureImage cropCenter(double aspectRatio)
Parameters
aspectRatio doublein Target aspect ratio (width/height) for the cropped image. Must be positive.
Returns
The cropped image with the specified aspect ratio.
Exceptions
An error has occurred during Devices Library execution.