Vector3 class

Constructors

Vector3([double? x, double? y, double? z])
Vector3.fromJSON(List<double>? json)
Vector3.init({double x = 0, double y = 0, double z = 0})

Properties

hashCode → int
The hash code for this object.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
type ↔ String
getter/setter pair
x ↔ double
getter/setter pair
y ↔ double
getter/setter pair
z ↔ double
getter/setter pair

Methods

add(Vector3 v) → Vector3
addScalar(num s) → Vector3
addScaledVector(Vector3 v, num s) → Vector3
addVectors(Vector3 a, Vector3 b) → Vector3
angleTo(dynamic v) → double
applyAxisAngle(dynamic axis, dynamic angle) → Vector3
applyEuler(Euler? euler) → Vector3
applyMatrix3(Matrix3 m) → Vector3
applyMatrix4(Matrix4 m) → Vector3
applyNormalMatrix(Matrix3 m) → dynamic
applyQuaternion(Quaternion q) → Vector3
ceil() → Vector3
clamp(Vector3 min, Vector3 max) → Vector3
clampLength<T extends num>(T min, T max) → Vector3
clampScalar(dynamic minVal, dynamic maxVal) → Vector3
clone() → Vector3
copy(dynamic v) → Vector3
cross(Vector3 v, {Vector3? w}) → Vector3
crossVectors(Vector3 a, Vector3 b) → Vector3
distanceTo(Vector3 v) → double
distanceToSquared(Vector3 v) → num
divide(Vector3 v) → Vector3
divideScalar(num scalar) → Vector3
dot(Vector3 v) → num
equals(dynamic v) → bool
floor() → Vector3
fromArray(dynamic array, [int offset = 0]) → Vector3
fromBufferAttribute(BufferAttribute<NativeArray<num>> attribute, int index) → Vector3
getComponent(int index) → double
length() → double
lengthSq() → num
lerp(Vector3 v, num alpha) → Vector3
lerpVectors(Vector3 v1, Vector3 v2, num alpha) → Vector3
manhattanDistanceTo(Vector3 v) → dynamic
manhattanLength() → num
max(Vector3 v) → Vector3
min(Vector3 v) → Vector3
multiply(Vector3 v) → Vector3
multiplyScalar(num scalar) → Vector3
multiplyVectors(Vector3 a, Vector3 b) → Vector3
negate() → Vector3
normalize() → Vector3
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
project(dynamic camera) → Vector3
projectOnPlane(Vector3 planeNormal) → Vector3
projectOnVector(Vector3 v) → Vector3
random() → Vector3
randomDirection() → Vector3
reflect(Vector3 normal) → Vector3
round() → Vector3
roundToZero() → void
set(double x, double y, [double? z]) → Vector3
setComponent(int index, double value) → Vector3
setFromCylindrical(dynamic c) → Vector3
setFromCylindricalCoords(double radius, double theta, double y) → Vector3
setFromEuler(Euler e) → Vector3
setFromMatrix3Column(Matrix3 m, int index) → Vector3
setFromMatrixColumn(Matrix4 m, int index) → Vector3
setFromMatrixPosition(dynamic m) → Vector3
setFromMatrixScale(dynamic m) → Vector3
setFromSpherical(dynamic s) → Vector3
setFromSphericalCoords(num radius, num phi, num theta) → Vector3
setLength(num length) → Vector3
setP(String p, double v) → void
setScalar(dynamic scalar) → Vector3
setX(double x) → Vector3
setY(double y) → Vector3
setZ(double z) → Vector3
sub(dynamic v, {Vector3? w}) → Vector3
subScalar(num s) → Vector3
subVectors(Vector3 a, Vector3 b) → Vector3
toArray([List<num>? array, int offset = 0]) → List<num>
toJSON() → List<num>
toString() → String
A string representation of this object.
inherited
transformDirection(Matrix4 m) → Vector3
unproject(dynamic camera) → Vector3

Operators

operator ==(Object other) → bool
The equality operator.
inherited