Package org.joml
Class Vector2f
java.lang.Object
org.joml.Vector2f
- All Implemented Interfaces:
Externalizable
,Serializable
,Vector2fc
- See Also:
-
Field Summary
-
Constructor Summary
ConstructorDescriptionVector2f()
Vector2f
(float float1) Vector2f
(float[] floatArray) Vector2f
(float float1, float float2) Vector2f
(int int1, ByteBuffer byteBuffer) Vector2f
(int int1, FloatBuffer floatBuffer) Vector2f
(ByteBuffer byteBuffer) Vector2f
(FloatBuffer floatBuffer) -
Method Summary
Modifier and TypeMethodDescriptionabsolute()
add
(float float1, float float2) float
ceil()
float
distance
(float float1, float float2) static float
distance
(float float1, float float2, float float3, float float4) float
float
distanceSquared
(float float1, float float2) static float
distanceSquared
(float float1, float float2, float float3, float float4) float
distanceSquared
(Vector2fc vector2fc) div
(float float1) div
(float float1, float float2) float
boolean
equals
(float float1, float float2) boolean
boolean
floor()
float
get
(int int1) get
(int int1, ByteBuffer byteBuffer) get
(int int1, FloatBuffer floatBuffer) get
(ByteBuffer byteBuffer) get
(FloatBuffer floatBuffer) getToAddress
(long long1) int
hashCode()
boolean
isFinite()
float
length()
static float
length
(float float1, float float2) float
static float
lengthSquared
(float float1, float float2) int
int
mul
(float float1) mul
(float float1, float float2) mulDirection
(Matrix3x2fc matrix3x2fc) mulDirection
(Matrix3x2fc matrix3x2fc, Vector2f vector2f) mulPosition
(Matrix3x2fc matrix3x2fc) mulPosition
(Matrix3x2fc matrix3x2fc, Vector2f vector2f) mulTranspose
(Matrix2fc matrix2fc) mulTranspose
(Matrix2fc matrix2fc, Vector2f vector2f) negate()
normalize
(float float1) void
readExternal
(ObjectInput objectInput) round()
set
(double double1) set
(double double1, double double2) set
(float float1) set
(float[] floatArray) set
(float float1, float float2) set
(int int1, ByteBuffer byteBuffer) set
(int int1, FloatBuffer floatBuffer) set
(ByteBuffer byteBuffer) set
(FloatBuffer floatBuffer) setComponent
(int int1, float float1) setFromAddress
(long long1) sub
(float float1, float float2) toString()
toString
(NumberFormat numberFormat) void
writeExternal
(ObjectOutput objectOutput) float
x()
float
y()
zero()
-
Field Details
-
x
public float x -
y
public float y
-
-
Constructor Details
-
Vector2f
public Vector2f() -
Vector2f
public Vector2f(float float1) -
Vector2f
public Vector2f(float float1, float float2) -
Vector2f
-
Vector2f
-
Vector2f
public Vector2f(float[] floatArray) -
Vector2f
-
Vector2f
-
Vector2f
-
Vector2f
-
-
Method Details
-
x
public float x() -
y
public float y() -
set
-
set
-
set
-
set
-
set
-
set
-
set
-
set
-
set
-
set
-
set
-
set
-
setFromAddress
-
get
- Specified by:
get
in interfaceVector2fc
- Throws:
IllegalArgumentException
-
get
-
get
-
get
-
setComponent
- Throws:
IllegalArgumentException
-
get
-
get
-
get
-
get
-
getToAddress
- Specified by:
getToAddress
in interfaceVector2fc
-
perpendicular
-
sub
-
sub
-
sub
-
sub
-
dot
-
angle
-
lengthSquared
public float lengthSquared()- Specified by:
lengthSquared
in interfaceVector2fc
-
lengthSquared
public static float lengthSquared(float float1, float float2) -
length
public float length() -
length
public static float length(float float1, float float2) -
distance
-
distanceSquared
- Specified by:
distanceSquared
in interfaceVector2fc
-
distance
public float distance(float float1, float float2) -
distanceSquared
public float distanceSquared(float float1, float float2) - Specified by:
distanceSquared
in interfaceVector2fc
-
distance
public static float distance(float float1, float float2, float float3, float float4) -
distanceSquared
public static float distanceSquared(float float1, float float2, float float3, float float4) -
normalize
-
normalize
-
normalize
-
normalize
-
add
-
add
-
add
-
add
-
zero
-
writeExternal
- Specified by:
writeExternal
in interfaceExternalizable
- Throws:
IOException
-
readExternal
- Specified by:
readExternal
in interfaceExternalizable
- Throws:
IOException
ClassNotFoundException
-
negate
-
negate
-
mul
-
mul
-
mul
-
mul
-
mul
-
mul
-
div
-
div
-
div
-
div
-
div
-
div
-
mul
-
mul
-
mul
-
mul
-
mulTranspose
-
mulTranspose
- Specified by:
mulTranspose
in interfaceVector2fc
-
mulPosition
-
mulPosition
- Specified by:
mulPosition
in interfaceVector2fc
-
mulDirection
-
mulDirection
- Specified by:
mulDirection
in interfaceVector2fc
-
lerp
-
lerp
-
hashCode
public int hashCode() -
equals
-
equals
-
equals
public boolean equals(float float1, float float2) -
toString
-
toString
-
fma
-
fma
-
fma
-
fma
-
min
-
min
-
max
-
max
-
maxComponent
public int maxComponent()- Specified by:
maxComponent
in interfaceVector2fc
-
minComponent
public int minComponent()- Specified by:
minComponent
in interfaceVector2fc
-
floor
-
floor
-
ceil
-
ceil
-
round
-
round
-
isFinite
public boolean isFinite() -
absolute
-
absolute
-