You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Barycentric: Returns a point in Barycentric coordinates.
CatmullRom: Performs a Catmull-Rom interpolation.
Hermite: Performs a Hermite spline interpolation.
Reflect: Reflects an incident vector across a normal vector.
Refract: Refracts an incident vector across a normal vector.
Transform: Transform the vector by the rotation and scale in the matrix or a quaternion. There is also an overload for transforming an array of vectors. See XMVector2Transform.
TransformNormal: Transforms the vector by the rotation and scale in the matrix, ignoring translation (rows 2 & 3). There is also an overload for transforming an array of vectors. See XMVector2TransformNormal.
Constants
Zero: Zero vector [0, 0]
One: One vector [1, 1]
UnitX: Unit X vector [1, 0]
UnitY: Unit Y vector [0, 1]
Exceptions
These methods are marked noexcept, and do not throw C++ exceptions.
Remark
Vector2 can freely convert to and from a XMFLOAT2 and XMVECTOR (the z and w components are lost).