Rotate
- class Rotate(angle: float)
A
Rotatetransformation rotates a vector around(0, 0, 0)by a given angleθ.This uses the axis-angle representation, but is restricted to the axis
(0, 0, 1). In the future, this can be updated to allow for rotations not in the XY-plane.Its matrix looks like:
┏ ┓ ┃ cos(θ) -sin(θ) 0 0 ┃ ┃ sin(θ) cos(θ) 0 0 ┃ ┃ 0 0 1 0 ┃ ┃ 0 0 0 1 ┃ ┗ ┛
Attributes
The angle to rotate by, θ.
cos(θ).sin(θ).Methods
Apply this
Rotateto a vector.The inverse
HomogeneousTransformationof this one.- inverse()
The inverse
HomogeneousTransformationof this one.
- angle
The angle to rotate by, θ.
- cos_angle
cos(θ).
- sin_angle
sin(θ).