fromRotationY

fun fromRotationY(angle: Double, result: Matrix3? = definedExternally): Matrix3(source)

Creates a rotation matrix around the y-axis.

// Rotate a point 45 degrees counterclockwise around the y-axis.
const p = new Cartesian3(5, 6, 7);
const m = Matrix3.fromRotationY(Math.toRadians(45.0));
const rotated = Matrix3.multiplyByVector(m, p, new Cartesian3());

Return

The modified result parameter, or a new Matrix3 instance if one was not provided.

Parameters

angle

The angle, in radians, of the rotation. Positive angles are counterclockwise.

result

The object in which the result will be stored, if undefined a new instance will be created.

See also