The input image
The points of the rectangle. Points must be circling around the rectangle (clockwise or anti-clockwise). The validity of the points passed is assumed and not checked.
Optional
options: CropRectangleOptionsCrop options, see CropRectangleOptions
The cropped image. The orientation of the image is the one closest to the rectangle passed as input.
Crop an oriented rectangle from an image. If the rectangle's length or width are not an integers, its dimension is expanded in both directions such as the length and width are integers.