FVector2

Inheritance: java.lang.Object

All Implemented Interfaces: com.aspose.threed.Struct, java.io.Serializable

public final class FVector2 implements Struct<FVector2>, Serializable

A float vector with two components.

Constructors

ConstructorDescription
FVector2(float x, float y)Initializes a new instance of the FVector2.
FVector2(Vector2 vec)Initializes a new instance of the FVector2.
FVector2()

Fields

FieldDescription
xThe x component.
yThe y component.

Methods

MethodDescription
add(FVector2 a, FVector2 b)+ Operator overloading
clone()
copyFrom(FVector2 src)
create(FVector2 v)Explicit conversion operator to cast FVector2 to Vector2
equals(FVector2 rhs)Check if two vectors are equal
equals(Object obj)Check if two vectors are equal
getClass()
hashCode()Gets the hash code of this instance
mul(FVector2 a, float b)* operator overloading
notify()
notifyAll()
op_eq(FVector2 a, FVector2 b)== Operator overloading
op_ne(FVector2 a, FVector2 b)!
sub(FVector2 a, FVector2 b)- Operator overloading
toString()Returns a string that represents the FVector2
wait()
wait(long arg0)
wait(long arg0, int arg1)

FVector2(float x, float y)

public FVector2(float x, float y)

Initializes a new instance of the FVector2.

Parameters:

ParameterTypeDescription
xfloatX component of the vector
yfloatY component of the vector

FVector2(Vector2 vec)

public FVector2(Vector2 vec)

Initializes a new instance of the FVector2.

Parameters:

ParameterTypeDescription
vecVector2Vector2 in double type

FVector2()

public FVector2()

x

public float x

The x component.

y

public float y

The y component.

add(FVector2 a, FVector2 b)

public static FVector2 add(FVector2 a, FVector2 b)

+ Operator overloading

Parameters:

ParameterTypeDescription
aFVector2First vector
bFVector2Second vector

Returns: FVector2 - The sum of two vectors.

clone()

public FVector2 clone()

Clone current instance

Returns: FVector2

copyFrom(FVector2 src)

public void copyFrom(FVector2 src)

Parameters:

ParameterTypeDescription
srcFVector2

create(FVector2 v)

public static Vector2 create(FVector2 v)

Explicit conversion operator to cast FVector2 to Vector2

Parameters:

ParameterTypeDescription
vFVector2Vector 2 in float type.

Returns: Vector2

equals(FVector2 rhs)

public boolean equals(FVector2 rhs)

Check if two vectors are equal

Parameters:

ParameterTypeDescription
rhsFVector2

Returns: boolean - True if all components are equal.

equals(Object obj)

public boolean equals(Object obj)

Check if two vectors are equal

Parameters:

ParameterTypeDescription
objjava.lang.Object

Returns: boolean - True if input is a vector and all components are equal.

getClass()

public final native Class<?> getClass()

Returns: java.lang.Class

hashCode()

public int hashCode()

Gets the hash code of this instance

Returns: int - The hash code of the vector.

mul(FVector2 a, float b)

public static FVector2 mul(FVector2 a, float b)

* operator overloading

Parameters:

ParameterTypeDescription
aFVector2First vector
bfloatSecond vector

Returns: FVector2 - The product of two vectors.

notify()

public final native void notify()

notifyAll()

public final native void notifyAll()

op_eq(FVector2 a, FVector2 b)

public static boolean op_eq(FVector2 a, FVector2 b)

== Operator overloading

Parameters:

ParameterTypeDescription
aFVector2First vector
bFVector2Second vector

Returns: boolean - True if all components are equal.

op_ne(FVector2 a, FVector2 b)

public static boolean op_ne(FVector2 a, FVector2 b)

!= Operator overloading

Parameters:

ParameterTypeDescription
aFVector2First vector
bFVector2Second vector

Returns: boolean - True if any component is different.

sub(FVector2 a, FVector2 b)

public static FVector2 sub(FVector2 a, FVector2 b)

- Operator overloading

Parameters:

ParameterTypeDescription
aFVector2First vector
bFVector2Second vector

Returns: FVector2 - The difference of two vectors.

toString()

public String toString()

Returns a string that represents the FVector2

Returns: java.lang.String - String representation of current vector.

wait()

public final void wait()

wait(long arg0)

public final void wait(long arg0)

Parameters:

ParameterTypeDescription
arg0long

wait(long arg0, int arg1)

public final void wait(long arg0, int arg1)

Parameters:

ParameterTypeDescription
arg0long
arg1int