Package org.joml
Class Vector4d
java.lang.Object
org.joml.Vector4d
- All Implemented Interfaces:
java.io.Externalizable
,java.io.Serializable
,Vector4dc
public class Vector4d extends java.lang.Object implements java.io.Externalizable, Vector4dc
- See Also:
- Serialized Form
-
Field Summary
-
Constructor Summary
Constructors Constructor Description Vector4d()
Vector4d(double d)
Vector4d(double x, double y, double z, double w)
Vector4d(int index, java.nio.ByteBuffer buffer)
Vector4d(int index, java.nio.DoubleBuffer buffer)
Vector4d(java.nio.ByteBuffer buffer)
Vector4d(java.nio.DoubleBuffer buffer)
Vector4d(Vector2dc v, double z, double w)
Vector4d(Vector2fc v, double z, double w)
Vector4d(Vector3dc v, double w)
Vector4d(Vector3fc v, double w)
Vector4d(Vector4dc v)
Vector4d(Vector4fc v)
-
Method Summary
Modifier and Type Method Description Vector4d
add(double x, double y, double z, double w)
Vector4d
add(double x, double y, double z, double w, Vector4d dest)
Vector4d
add(Vector4dc v)
Vector4d
add(Vector4fc v)
double
angle(Vector4dc v)
double
angleCos(Vector4dc v)
double
distance(double x, double y, double z, double w)
double
distance(Vector4dc v)
Vector4d
div(double scalar)
Vector4d
div(double scalar, Vector4d dest)
Vector4d
div(Vector4dc v)
Vector4d
div(Vector4dc v, Vector4d dest)
double
dot(double x, double y, double z, double w)
double
dot(Vector4dc v)
boolean
equals(java.lang.Object obj)
Vector4d
fma(double a, Vector4dc b)
Vector4d
fma(double a, Vector4dc b, Vector4d dest)
Vector4d
fma(Vector4dc a, Vector4dc b)
Vector4d
fma(Vector4dc a, Vector4dc b, Vector4d dest)
java.nio.ByteBuffer
get(int index, java.nio.ByteBuffer buffer)
java.nio.DoubleBuffer
get(int index, java.nio.DoubleBuffer buffer)
java.nio.ByteBuffer
get(java.nio.ByteBuffer buffer)
java.nio.DoubleBuffer
get(java.nio.DoubleBuffer buffer)
int
hashCode()
Vector4d
hermite(Vector4dc t0, Vector4dc v1, Vector4dc t1, double t, Vector4d dest)
double
length()
double
lengthSquared()
Vector4d
lerp(Vector4dc other, double t)
Vector4d
lerp(Vector4dc other, double t, Vector4d dest)
Vector4d
mul(double scalar)
Vector4d
mul(double scalar, Vector4d dest)
Vector4d
mul(Matrix4dc mat)
Vector4d
mul(Matrix4dc mat, Vector4d dest)
Vector4d
mul(Matrix4fc mat)
Vector4d
mul(Matrix4fc mat, Vector4d dest)
Vector4d
mul(Matrix4x3dc mat)
Vector4d
mul(Matrix4x3dc mat, Vector4d dest)
Vector4d
mul(Matrix4x3fc mat)
Vector4d
mul(Matrix4x3fc mat, Vector4d dest)
Vector4d
mul(Vector4dc v)
Vector4d
mul(Vector4dc v, Vector4d dest)
Vector4d
mul(Vector4fc v)
Vector4d
mulProject(Matrix4dc mat)
Vector4d
mulProject(Matrix4dc mat, Vector4d dest)
Vector4d
negate()
Vector4d
negate(Vector4d dest)
Vector4d
normalize()
Vector4d
normalize(Vector4d dest)
Vector4d
normalize3()
Vector4d
normalize3(Vector4d dest)
void
readExternal(java.io.ObjectInput in)
Vector4d
rotate(Quaterniondc quat)
Vector4d
rotate(Quaterniondc quat, Vector4d dest)
Vector4d
set(double d)
Vector4d
set(double x, double y, double z, double w)
Vector4d
set(int index, java.nio.ByteBuffer buffer)
Vector4d
set(int index, java.nio.DoubleBuffer buffer)
Vector4d
set(java.nio.ByteBuffer buffer)
Vector4d
set(java.nio.DoubleBuffer buffer)
Vector4d
set(Vector2dc v, double z, double w)
Vector4d
set(Vector2fc v, double z, double w)
Vector4d
set(Vector3dc v, double w)
Vector4d
set(Vector3fc v, double w)
Vector4d
set(Vector4dc v)
Vector4d
set(Vector4fc v)
Vector4d
setComponent(int component, double value)
Vector4d
smoothStep(Vector4dc v, double t, Vector4d dest)
Vector4d
sub(double x, double y, double z, double w)
Vector4d
sub(double x, double y, double z, double w, Vector4d dest)
Vector4d
sub(Vector4dc v)
Vector4d
sub(Vector4fc v)
Vector4dc
toImmutable()
java.lang.String
toString()
java.lang.String
toString(java.text.NumberFormat formatter)
double
w()
void
writeExternal(java.io.ObjectOutput out)
double
x()
double
y()
double
z()
Vector4d
zero()
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Field Details
-
x
public double x -
y
public double y -
z
public double z -
w
public double w
-
-
Constructor Details
-
Vector4d
public Vector4d() -
Vector4d
-
Vector4d
-
Vector4d
-
Vector4d
public Vector4d(double d) -
Vector4d
-
Vector4d
-
Vector4d
-
Vector4d
public Vector4d(double x, double y, double z, double w) -
Vector4d
public Vector4d(java.nio.ByteBuffer buffer) -
Vector4d
public Vector4d(int index, java.nio.ByteBuffer buffer) -
Vector4d
public Vector4d(java.nio.DoubleBuffer buffer) -
Vector4d
public Vector4d(int index, java.nio.DoubleBuffer buffer)
-
-
Method Details
-
x
public double x() -
y
public double y() -
z
public double z() -
w
public double w() -
set
-
set
-
set
-
set
-
set
-
set
-
set
-
set
-
set
-
set
-
set
-
set
-
setComponent
public Vector4d setComponent(int component, double value) throws java.lang.IllegalArgumentException- Throws:
java.lang.IllegalArgumentException
-
get
public java.nio.ByteBuffer get(java.nio.ByteBuffer buffer) -
get
public java.nio.ByteBuffer get(int index, java.nio.ByteBuffer buffer) -
get
public java.nio.DoubleBuffer get(java.nio.DoubleBuffer buffer) -
get
public java.nio.DoubleBuffer get(int index, java.nio.DoubleBuffer buffer) -
sub
-
sub
-
sub
-
sub
-
add
-
add
-
add
-
add
-
fma
-
fma
-
fma
-
fma
-
mul
-
mul
-
div
-
div
-
mul
-
mul
-
mul
-
mul
-
mul
-
mul
-
mul
-
mul
-
mul
-
mulProject
- Specified by:
mulProject
in interfaceVector4dc
-
mulProject
-
mul
-
mul
-
div
-
div
-
rotate
-
rotate
-
lengthSquared
public double lengthSquared()- Specified by:
lengthSquared
in interfaceVector4dc
-
length
public double length() -
normalize
-
normalize
-
normalize3
-
normalize3
- Specified by:
normalize3
in interfaceVector4dc
-
distance
-
distance
public double distance(double x, double y, double z, double w) -
dot
-
dot
public double dot(double x, double y, double z, double w) -
angleCos
-
angle
-
zero
-
negate
-
negate
-
toString
public java.lang.String toString()- Overrides:
toString
in classjava.lang.Object
-
toString
public java.lang.String toString(java.text.NumberFormat formatter) -
writeExternal
public void writeExternal(java.io.ObjectOutput out) throws java.io.IOException- Specified by:
writeExternal
in interfacejava.io.Externalizable
- Throws:
java.io.IOException
-
readExternal
public void readExternal(java.io.ObjectInput in) throws java.io.IOException, java.lang.ClassNotFoundException- Specified by:
readExternal
in interfacejava.io.Externalizable
- Throws:
java.io.IOException
java.lang.ClassNotFoundException
-
hashCode
public int hashCode()- Overrides:
hashCode
in classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)- Overrides:
equals
in classjava.lang.Object
-
smoothStep
- Specified by:
smoothStep
in interfaceVector4dc
-
hermite
-
lerp
-
lerp
-
toImmutable
-