Skip to content
This repository has been archived by the owner on Aug 28, 2024. It is now read-only.

Commit

Permalink
feat: renamed transformMatrix2D
Browse files Browse the repository at this point in the history
  • Loading branch information
tmgulland committed Jun 7, 2024
1 parent 7b9e5fe commit 1254e14
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/vector2.ts
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ export const dot = (a: Vector2, b: Vector2) => a.x * b.x + a.y * b.y
export const lerp = (v: Vector2, a: Vector2, b: Vector2, amount: number) =>
set(v, _lerp(a.x, b.x, amount), _lerp(a.y, b.y, amount))

export const transformMatrix2D = (v: Vector2, a: Vector2, m: Matrix2D) =>
export const transform = (v: Vector2, a: Vector2, m: Matrix2D) =>
set(v, m[0] * a.x + m[2] * a.y + m[4], m[1] * a.x + m[3] * a.y + m[5])

export const rotate = (v: Vector2, a: Vector2, b: Vector2, rad: number) => {
Expand Down

0 comments on commit 1254e14

Please # to comment.