Vec3 extension

on
  • Vector3

Methods

add2(Vector3 a, Vector3 b) → Vector3

Available on Vector3, provided by the Vec3 extension

add vector a to vector b
applyMatrix3Transpose(Matrix3 m) → Vector3

Available on Vector3, provided by the Vec3 extension

Apply a 3x3 Matrix to this vector
cross2(Vector3 a, Vector3 b) → Vector3

Available on Vector3, provided by the Vec3 extension

Cross a with b
equals(Vector3 v) bool

Available on Vector3, provided by the Vec3 extension

Is v == to this
inverse() → Vector3

Available on Vector3, provided by the Vec3 extension

Invert this vector
lerp(Vector3 v, num alpha) → Vector3

Available on Vector3, provided by the Vec3 extension

scale2(Vector3 v, double s) → Vector3

Available on Vector3, provided by the Vec3 extension

scale vector v with s and set for this vector
sub2(Vector3 a, Vector3 b) → Vector3

Available on Vector3, provided by the Vec3 extension

Subtract a from b
subScaledVector(Vector3 v, double s) → Vector3

Available on Vector3, provided by the Vec3 extension

Subtract v scaled by s with this vector
tangent(Vector3 a) → Vector3

Available on Vector3, provided by the Vec3 extension

Get the tangent of this vector with respect to a
testDiff(Vector3 v) bool

Available on Vector3, provided by the Vec3 extension

Check if v is different to this
testZero() bool

Available on Vector3, provided by the Vec3 extension

Test if all the positions are zero e.g(x=y=z=0)