rotateImage

fun rotateImage(imageToRotatePath: String, rotatedImagePath: String, angle: RotationAngle, isBinary: Boolean = false)

Rotate an image.

Parameters

imageToRotatePath

Path to the input image

rotatedImagePath

Desired path to the output image

angle

Rotation angle

isBinary

True if the image has only black and white pixels

Throws

if input file cannot be read or output folder does not exist


Rotate an image.

Return

The rotated image bitmap

Parameters

image

Image bitmap to rotate

angle

Rotation angle.

Throws

if rotation fails (eg if bitmap is not valid)