Vector4
Vector4
Kind: global class
- Vector4
- new Vector4([x], [y], [z], [w])
- instance
- .readFromArray(array, offset)
- .writeToArray(array, offset)
- .set(x, y, z, w) ⇒
Vector4
- .multiplyVector3(v3)
- .multiplyScalar(value) ⇒
Vector4
- ._applyMatrix4(a0, a1, a2, a3, b0, b1, b2, b3, c0, c1, c2, c3, d0, d1, d2, d3) ⇒
Vector4
- .dot(other) ⇒
number
- .add3(v3) ⇒
Vector4
- .threeApplyMatrix4(m) ⇒
Vector4
- .copy(vec4) ⇒
Vector4
- .clone() ⇒
Vector4
- .applyQuaternion(q)
- .equals(vec4) ⇒
boolean
- .hash() ⇒
number
- .lerpVectors(v0, v1, f)
- .toArray(result)
- .asArray() ⇒
Array.<number>
- .setFromArray(data, offset)
- .toBinaryBuffer(buffer)
- .fromBinaryBuffer(buffer)
- static
new Vector4([x], [y], [z], [w])
Param | Type | Default |
---|---|---|
[x] | Number | 0 |
[y] | Number | 0 |
[z] | Number | 0 |
[w] | Number | 0 |
vector4.readFromArray(array, offset)
Kind: instance method of Vector4
Param | Type | Default |
---|---|---|
array | Array.<number> | |
offset | number | 0 |
vector4.writeToArray(array, offset)
Kind: instance method of Vector4
Param | Type | Default |
---|---|---|
array | Array.<number> | |
offset | number | 0 |
vector4.set(x, y, z, w) ⇒ Vector4
Kind: instance method of Vector4
Param | Type |
---|---|
x | Number |
y | Number |
z | Number |
w | Number |
vector4.multiplyVector3(v3)
Kind: instance method of Vector4
Param | Type |
---|---|
v3 | Vector3 |
vector4.multiplyScalar(value) ⇒ Vector4
Kind: instance method of Vector4
Param | Type |
---|---|
value | Number |
vector4._applyMatrix4(a0, a1, a2, a3, b0, b1, b2, b3, c0, c1, c2, c3, d0, d1, d2, d3) ⇒ Vector4
Kind: instance method of Vector4
Returns: Vector4
- this
Param | Type |
---|---|
a0 | number |
a1 | number |
a2 | number |
a3 | number |
b0 | number |
b1 | number |
b2 | number |
b3 | number |
c0 | number |
c1 | number |
c2 | number |
c3 | number |
d0 | number |
d1 | number |
d2 | number |
d3 | number |
vector4.dot(other) ⇒ number
Kind: instance method of Vector4
Param | Type |
---|---|
other | Vector4 |
vector4.add3(v3) ⇒ Vector4
Add XYZ components from another vector
Kind: instance method of Vector4
Param | Type |
---|---|
v3 | Vector3 | Vector4 |
vector4.threeApplyMatrix4(m) ⇒ Vector4
Kind: instance method of Vector4
Returns: Vector4
- this
Param | Type |
---|---|
m | Matrix4 |
vector4.copy(vec4) ⇒ Vector4
Kind: instance method of Vector4
Param | Type |
---|---|
vec4 | Vector4 |
vector4.clone() ⇒ Vector4
Kind: instance method of Vector4
vector4.applyQuaternion(q)
Kind: instance method of Vector4
Param | Type |
---|---|
q | Quaternion |
vector4.equals(vec4) ⇒ boolean
Kind: instance method of Vector4
Param | Type |
---|---|
vec4 | Vector4 |
vector4.hash() ⇒ number
Kind: instance method of Vector4
vector4.lerpVectors(v0, v1, f)
Kind: instance method of Vector4
Param | Type | Description |
---|---|---|
v0 | Vector4 | |
v1 | Vector4 | |
f | Number | interpolation fraction |
vector4.toArray(result)
Kind: instance method of Vector4
Param | Type |
---|---|
result | Array.<number> |
vector4.asArray() ⇒ Array.<number>
Kind: instance method of Vector4
vector4.setFromArray(data, offset)
Kind: instance method of Vector4
Param | Type |
---|---|
data | Array.<number> |
offset | number |
vector4.toBinaryBuffer(buffer)
Kind: instance method of Vector4
Param | Type |
---|---|
buffer | BinaryBuffer |
vector4.fromBinaryBuffer(buffer)
Kind: instance method of Vector4
Param | Type |
---|---|
buffer | BinaryBuffer |
Vector4.lerp(v0, v1, f, result)
Kind: static method of Vector4
Param | Type | Description |
---|---|---|
v0 | Vector4 | |
v1 | Vector4 | |
f | Number | interpolation fraction |
result | Vector4 |