Geometry

Vec2

A direction and a length, such as an offset or a velocity.

Object type geometry pins

A Vec2 is a vector: an x and a y offset. Unlike a Point, it isn't a place but a move from one: the vector nodes add, scale and measure them.

Hierarchy

Parents
None
Subtypes
None

Properties

NameTypeNotes
xnumber
ynumber
magnitudenumberread-only
normalVec2Vec2read-only

Nodes

Break Vec2

Node id break/Vec2

Inputs

NameTypeDefaultNotes
objectVec2type default

Outputs

NameTypeNotes
xnumber
ynumber
magnitudenumber
normalVec2Vec2

Make Vec2

Node id make/Vec2

Inputs

NameTypeDefaultNotes
xnumber0
ynumber0

Outputs

NameTypeNotes
objectVec2

Set Vec2

Node id set/Vec2

Inputs

NameTypeDefaultNotes
objectVec2type default
xnumber—
ynumber—

Outputs

NameTypeNotes
objectVec2

Lerp Vec2

Node id lerp/Vec2

Inputs

NameTypeDefaultNotes
aVec2type default
bVec2type default
tnumber0.5

Outputs

NameTypeNotes
resultVec2

Notes

  • Read-only properties. Break Vec2 also gives its magnitude (its length) and normalVec2, a vector of length 1 at a right angle to it.
  • Not a Point. Vec2 and Point don't connect to each other. Use Vector From Points to get the vector between two points, or Break and Make to convert.
  • Default. Make Vec2 gives (0, 0).

Lerp

Lerp Vec2 blends x and y. t is clamped to 0, 1.

© 2026 Wirepaint