You are here: Start » AVL.NET » AVL.RotateImage Method

AVL.RotateImage Method

Rotates an image clockwise.

Namespace:AvlNet
Assembly:AVL.NET.dll

Syntax

public static void RotateImage(
	AvlNet.Image inImage,
	float inAngle,
	AvlNet.RotationSizeMode inSizeMode,
	AvlNet.InterpolationMethod inInterpolationMethod,
	bool inInverse,
	out AvlNet.Image outImage
)

Parameters

Name Type Range Default Description
inImageAvlNet.ImageInput image.
inAnglefloat45.0fRotation angle (clockwise). Default value: 45.0f.
inSizeModeAvlNet.RotationSizeMode
inInterpolationMethodAvlNet.InterpolationMethodBilinearDefault value: Bilinear.
inInverseboolFalse'True' changes rotation to counter-clockwise. Default value: False.
outImageAvlNet.ImageOutput image.

Description

The operation rotates the inImage around its center. Dimensions of the resulting image depends on inSizeMode parameter. In 'Fit' mode size is extended to fit the rotated image. In 'Preserve' mode size of source image is left unchanged and part of rotated image may be lost. Two modes of pixel interpolation are available, the bilinear filtering being more precise and computationally expensive.

Examples

RotateImage performed on the sample image in Fit mode with inAngle = 20.0.

Hardware Acceleration

This operation supports automatic parallelization for multicore and multiprocessor systems.

Hardware acceleration settings may be manipulated with Settings class.

Errors

Error type Description
DomainError Image dimensions too big in RotateImage.

See also