Back to FabImage Studio website

You are here: Start » Filter Reference » Region » Region Spatial Transforms » RotateRegion

RotateRegion


Module: FoundationBasic

Rotates a region around a specified point.

Name Type Range Description
Input value inRegion Region Input region
Input value inCenter Point2D* Center of rotation
Input value inAngle Real Clockwise rotation angle
Input value inInverse Bool Switches to counter-clockwise rotation
Input value inSizeMode RotationSizeMode Determines whether to extent the region size to fit the rotated region.
Input value inFrameWidth Integer* 0 - 65535 Output region frame width, ignored when inSizeMode is set to RotationSizeMode::Fit.
Input value inFrameHeight Integer* 0 - 65535 Output region frame height, ignored when inSizeMode is set to RotationSizeMode::Fit.
Output value outRegion Region Output region
Output value outOutputAlignment CoordinateSystem2D Alignment of the output region

Description

The operation rotates a region by the inAngle degrees around inCenter point. If the inCenter is not provided, the rotation is conducted around the mass center of the region.

Examples

RotateRegion performed on the sample region with inAngle set to 45.

Errors

This filter can throw an exception to report error. Read how to deal with errors in Error Handling.

List of possible exceptions:

Error type Description
DomainError Empty region on input when rotation center is Nil in RotateRegion.

Complexity Level

This filter is available on Advanced Complexity Level.

See Also

  • TranslateRegion – Translates a region by a given number of pixels along each axis.