Transform2D

A 2D transform

Constructors

this
this(Transform2D parent)

Create a new 2D transform

this
this(vec2 position, vec2 origin, vec2 scale, float rotation, Transform2D parent)

Create a new 2D transform

Members

Functions

changeParent
void changeParent(Transform2D parent)

Changes the transform's parent

matrix
mat4 matrix()

Gets the calculated matrix for this transform

Variables

origin
vec2 origin;

Position of the transform origin

position
vec2 position;

Position of transform

rotation
float rotation;

Rotation of transform

scale
vec2 scale;

Scale of transform

Meta