AffineTransformation

smile.modeling.AffineTransformation
See theAffineTransformation companion class

Provides factory methods for creating common affine transformations, including flips and rotations, relative to various axes and points.

Attributes

Companion
class
Graph
Supertypes
trait Product
trait Mirror
class Object
trait Matchable
class Any
Self type

Members list

Type members

Inherited types

type MirroredElemLabels <: Tuple

The names of the product elements

The names of the product elements

Attributes

Inherited from:
Mirror
type MirroredLabel <: String

The name of the type

The name of the type

Attributes

Inherited from:
Mirror

Value members

Concrete methods

def forOriginRelativeDiagonalFlipOf(horizontalSize: Double, verticalSize: Double): AffineTransformation

Creates an affine transformation for a diagonal flip about the origin, flipping both horizontally and vertically.

Creates an affine transformation for a diagonal flip about the origin, flipping both horizontally and vertically.

Value parameters

horizontalSize

The width of the image in pixels.

verticalSize

The height of the image in pixels.

Attributes

Returns

An affine transformation that flips the image diagonally.

def forPointCentredRotation(angle: Double, pX: Double, pY: Double): AffineTransformation

Creates an affine transformation for rotation about a specified point.

Creates an affine transformation for rotation about a specified point.

Value parameters

angle

The angle of rotation in degrees.

pX

The X-coordinate of the point around which to rotate.

pY

The Y-coordinate of the point around which to rotate.

Attributes

Returns

An affine transformation representing the rotation.

def forPointCentredRotation(cos: Double, sin: Double, pX: Double, pY: Double): AffineTransformation

Creates an affine transformation for rotation about a specified point using precomputed cosine and sine values.

Creates an affine transformation for rotation about a specified point using precomputed cosine and sine values.

Value parameters

cos

The cosine of the rotation angle.

pX

The X-coordinate of the point around which to rotate.

pY

The Y-coordinate of the point around which to rotate.

sin

The sine of the rotation angle.

Attributes

Returns

An affine transformation representing the rotation.

Creates an affine transformation for a vertical flip about the X-axis.

Creates an affine transformation for a vertical flip about the X-axis.

Value parameters

verticalSize

The height of the image in pixels.

Attributes

Returns

An affine transformation that flips the image vertically.

Creates an affine transformation for a horizontal flip about the Y-axis.

Creates an affine transformation for a horizontal flip about the Y-axis.

Value parameters

horizontalSize

The width of the image in pixels.

Attributes

Returns

An affine transformation that flips the image horizontally.

Concrete fields

Represents the identity transformation, which makes no changes to the coordinates.

Represents the identity transformation, which makes no changes to the coordinates.

Attributes