Basics

Guides

API Reference

Menu

Basics

Guides

API Reference

class: Affine

[13:7] extends: Transform

Wraps JavaFX Affine, a general 3D affine transform expressed as a 3x4 matrix (12 elements for rotation, scaling, shearing, and translation). Use Affine when a single transform needs to combine several effects or when you need to author the matrix elements directly.

Methods

  • Affine ()

    Creates a new identity Affine transform.

  • setElement (int Row, int Col, double Value)

    Sets the value at the given row and column of the affine matrix. Valid rows are 0, 1, 2. Valid columns are 0, 1, 2, 3 (column 3 is translation).

    • @p Row is an int with the matrix row.
    • @p Col is an int with the matrix column.
    • @p Value is a double with the new element value.
    • @r this object
  • setTx (double X)

    Sets the translation X component (matrix element [0, 3]).

    • @p X is a double with the translation X value.
    • @r this object
  • setTy (double Y)

    Sets the translation Y component (matrix element [1, 3]).

    • @p Y is a double with the translation Y value.
    • @r this object
  • setTz (double Z)

    Sets the translation Z component (matrix element [2, 3]).

    • @p Z is a double with the translation Z value.
    • @r this object
  • appendTranslation (double X, double Y, double Z)

    Appends a translation to this affine transform in place.

    • @p X is a double with the X translation.
    • @p Y is a double with the Y translation.
    • @p Z is a double with the Z translation.
    • @r this object
  • append (object Tx)

    Appends another Transform to this affine transform in place. Wraps the overload that accepts a Transform.

    • @p Tx is a Transform wrapper to append.
    • @r this object
  • appendRotation (double Angle)

    Appends a rotation about the Z axis (in degrees) to this affine transform. Wraps the single-angle overload.

    • @p Angle is a double with the rotation angle in degrees.
    • @r this object
  • appendScale (double Sx, double Sy)

    Appends a 2D scale to this affine transform in place. Wraps the (double, double) overload.

    • @p Sx is a double scale factor along the X axis.
    • @p Sy is a double scale factor along the Y axis.
    • @r this object
  • appendShear (double Shx, double Shy)

    Appends a 2D shear to this affine transform in place. Wraps the (double, double) overload.

    • @p Shx is a double shear factor along the X axis.
    • @p Shy is a double shear factor along the Y axis.
    • @r this object
  • createConcatenation (object Tx)

    Returns a new Transform that is the concatenation of this transform with the supplied Transform.

    • @p Tx is the Transform wrapper to concatenate with.
    • @r An AJO holding the resulting javafx.scene.transform.Transform.
  • createInverse ()

    Returns a new Affine that is the inverse of this transform. The underlying Java call throws NonInvertibleTransformException when the matrix is not invertible. The exception surfaces as a regular Aussom exception.

    • @r An AJO holding the inverse javafx.scene.transform.Affine.
  • deltaTransform (double X, double Y)

    Transforms only the vector portion (no translation) of a 2D point. Wraps the (double, double) overload that returns a Point2D.

    • @p X is a double with the input X coordinate.
    • @p Y is a double with the input Y coordinate.
    • @r An AJO holding the resulting javafx.geometry.Point2D.
  • determinant ()

    Returns the determinant of this affine transform.

    • @r A double with the matrix determinant.
  • getMxx ()

    Returns matrix element [0, 0].

    • @r A double with the Mxx value.
  • getMxy ()

    Returns matrix element [0, 1].

    • @r A double with the Mxy value.
  • getMxz ()

    Returns matrix element [0, 2].

    • @r A double with the Mxz value.
  • getMyx ()

    Returns matrix element [1, 0].

    • @r A double with the Myx value.
  • getMyy ()

    Returns matrix element [1, 1].

    • @r A double with the Myy value.
  • getMyz ()

    Returns matrix element [1, 2].

    • @r A double with the Myz value.
  • getMzx ()

    Returns matrix element [2, 0].

    • @r A double with the Mzx value.
  • getMzy ()

    Returns matrix element [2, 1].

    • @r A double with the Mzy value.
  • getMzz ()

    Returns matrix element [2, 2].

    • @r A double with the Mzz value.
  • getTx ()

    Returns the translation X component (matrix element [0, 3]).

    • @r A double with the Tx value.
  • getTy ()

    Returns the translation Y component (matrix element [1, 3]).

    • @r A double with the Ty value.
  • getTz ()

    Returns the translation Z component (matrix element [2, 3]).

    • @r A double with the Tz value.
  • inverseDeltaTransform (double X, double Y)

    Inverse-transforms the vector portion (no translation) of a 2D point. The underlying Java call throws NonInvertibleTransformException when the matrix is not invertible. Wraps the (double, double) overload.

    • @p X is a double with the input X coordinate.
    • @p Y is a double with the input Y coordinate.
    • @r An AJO holding the resulting javafx.geometry.Point2D.
  • inverseTransform (double X, double Y)

    Inverse-transforms a 2D point through this transform. The underlying Java call throws NonInvertibleTransformException when the matrix is not invertible. Wraps the (double, double) overload.

    • @p X is a double with the input X coordinate.
    • @p Y is a double with the input Y coordinate.
    • @r An AJO holding the resulting javafx.geometry.Point2D.
  • invert ()

    Inverts this affine transform in place. Throws NonInvertibleTransformException if the matrix is not invertible.

    • @r this object
  • mxxProperty ()

    Returns the property holding the Mxx matrix element.

    • @r A DoubleProperty AJO.
  • mxyProperty ()

    Returns the property holding the Mxy matrix element.

    • @r A DoubleProperty AJO.
  • mxzProperty ()

    Returns the property holding the Mxz matrix element.

    • @r A DoubleProperty AJO.
  • myxProperty ()

    Returns the property holding the Myx matrix element.

    • @r A DoubleProperty AJO.
  • myyProperty ()

    Returns the property holding the Myy matrix element.

    • @r A DoubleProperty AJO.
  • myzProperty ()

    Returns the property holding the Myz matrix element.

    • @r A DoubleProperty AJO.
  • mzxProperty ()

    Returns the property holding the Mzx matrix element.

    • @r A DoubleProperty AJO.
  • mzyProperty ()

    Returns the property holding the Mzy matrix element.

    • @r A DoubleProperty AJO.
  • mzzProperty ()

    Returns the property holding the Mzz matrix element.

    • @r A DoubleProperty AJO.
  • prepend (object Tx)

    Prepends another Transform to this affine transform in place. Wraps the overload that accepts a Transform.

    • @p Tx is a Transform wrapper to prepend.
    • @r this object
  • prependRotation (double Angle)

    Prepends a rotation about the Z axis (in degrees) to this affine transform. Wraps the single-angle overload.

    • @p Angle is a double with the rotation angle in degrees.
    • @r this object
  • prependScale (double Sx, double Sy)

    Prepends a 2D scale to this affine transform in place. Wraps the (double, double) overload.

    • @p Sx is a double scale factor along the X axis.
    • @p Sy is a double scale factor along the Y axis.
    • @r this object
  • prependShear (double Shx, double Shy)

    Prepends a 2D shear to this affine transform in place. Wraps the (double, double) overload.

    • @p Shx is a double shear factor along the X axis.
    • @p Shy is a double shear factor along the Y axis.
    • @r this object
  • prependTranslation (double X, double Y, double Z)

    Prepends a 3D translation to this affine transform in place. Wraps the (double, double, double) overload.

    • @p X is a double with the X translation.
    • @p Y is a double with the Y translation.
    • @p Z is a double with the Z translation.
    • @r this object
  • setMxx (double V)

    Sets matrix element [0, 0].

    • @p V is a double with the new Mxx value.
    • @r this object
  • setMxy (double V)

    Sets matrix element [0, 1].

    • @p V is a double with the new Mxy value.
    • @r this object
  • setMxz (double V)

    Sets matrix element [0, 2].

    • @p V is a double with the new Mxz value.
    • @r this object
  • setMyx (double V)

    Sets matrix element [1, 0].

    • @p V is a double with the new Myx value.
    • @r this object
  • setMyy (double V)

    Sets matrix element [1, 1].

    • @p V is a double with the new Myy value.
    • @r this object
  • setMyz (double V)

    Sets matrix element [1, 2].

    • @p V is a double with the new Myz value.
    • @r this object
  • setMzx (double V)

    Sets matrix element [2, 0].

    • @p V is a double with the new Mzx value.
    • @r this object
  • setMzy (double V)

    Sets matrix element [2, 1].

    • @p V is a double with the new Mzy value.
    • @r this object
  • setMzz (double V)

    Sets matrix element [2, 2].

    • @p V is a double with the new Mzz value.
    • @r this object
  • setToIdentity ()

    Resets this affine transform to the identity matrix.

    • @r this object
  • setToTransform (object Tx)

    Replaces this transform's matrix with the values from another Transform. Wraps the overload that accepts a single Transform.

    • @p Tx is a Transform wrapper providing the source matrix.
    • @r this object
  • transform (double X, double Y)

    Transforms a 2D point through this affine transform. Wraps the (double, double) overload that returns a Point2D.

    • @p X is a double with the input X coordinate.
    • @p Y is a double with the input Y coordinate.
    • @r An AJO holding the resulting javafx.geometry.Point2D.
  • txProperty ()

    Returns the property holding the Tx translation element.

    • @r A DoubleProperty AJO.
  • tyProperty ()

    Returns the property holding the Ty translation element.

    • @r A DoubleProperty AJO.
  • tzProperty ()

    Returns the property holding the Tz translation element.

    • @r A DoubleProperty AJO.