Vector2

Inheritance: java.lang.Object

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

public final class Vector2 implements Comparable<Vector2>, Struct<Vector2>, Serializable

2 つの成分を持つベクトル。

コンストラクタ

コンストラクタ説明
Vector2(double s)Vector2 構造体の新しいインスタンスを初期化します。
Vector2(Vector3 s)Vector2 構造体の新しいインスタンスを初期化します。
Vector2(FVector2 vec)Vector2 構造体の新しいインスタンスを初期化します。
Vector2(double x, double y)Vector2 構造体の新しいインスタンスを初期化します。
Vector2()

フィールド

フィールド説明
xx 成分。
yy 成分。

メソッド

メソッド説明
add(Vector2 lhs, Vector2 rhs)Vector2 の加算演算子
clone()
compareTo(Vector2 other)現在のベクトルを別のインスタンスと比較します。
copyFrom(Vector2 src)
create(Vector2 v)Vector2 を FVector2 にキャストする明示的変換演算子
cross(Vector2 v)2つのベクトルの外積
div(Vector2 lhs, double rhs)Vector2 の除算演算子
dot(Vector2 rhs)2つのベクトルのドット積を取得します
equals(Vector2 rhs)二つの vector2 が等しいかチェックします
equals(Object obj)二つの vector2 が等しいかチェックします
getClass()
getLength()長さを取得します。
getU()Vector2 がマッピング座標として使用される場合の U 成分を取得します。
getV()Vector2 がマッピング座標として使用される場合の V 成分を取得します。
hashCode()Vector2 のハッシュコードを取得します
mul(Vector2 lhs, double rhs)Vector2 の乗算演算子
mul(double lhs, Vector2 rhs)Vector2 の乗算演算子
normalize()このインスタンスを正規化します。
notify()
notifyAll()
op_eq(Vector2 lhs, Vector2 rhs)Vector2 の等価演算子
op_ne(Vector2 lhs, Vector2 rhs)Vector2 の不等価演算子
setU(double value)Vector2 がマッピング座標として使用されている場合、U 成分を設定します。
setV(double value)Vector2 がマッピング座標として使用されている場合、V 成分を設定します。
sub(Vector2 lhs, Vector2 rhs)Vector2 の減算演算子
toString()現在の Vector2 を表す java.lang.String を返します。
wait()
wait(long arg0)
wait(long arg0, int arg1)

Vector2(double s)

public Vector2(double s)

Vector2 構造体の新しいインスタンスを初期化します。

Parameters:

パラメーター説明
sdoubleS。

Vector2(Vector3 s)

public Vector2(Vector3 s)

Vector2 構造体の新しいインスタンスを初期化します。

Parameters:

パラメーター説明
sVector3S。

Vector2(FVector2 vec)

public Vector2(FVector2 vec)

Vector2 構造体の新しいインスタンスを初期化します。

Parameters:

パラメーター説明
vecFVector2float 型のベクトル。

Vector2(double x, double y)

public Vector2(double x, double y)

Vector2 構造体の新しいインスタンスを初期化します。

Parameters:

パラメーター説明
xdoublex 座標。
ydoubley 座標。

Vector2()

public Vector2()

x

public double x

x 成分。

y

public double y

y 成分。

add(Vector2 lhs, Vector2 rhs)

public static Vector2 add(Vector2 lhs, Vector2 rhs)

Vector2 の加算演算子

Parameters:

パラメーター説明
lhsVector2左側の値。
rhsVector2右側の値。

Returns: Vector2 - The result of addition.

clone()

public Vector2 clone()

現在のインスタンスをクローンする

Returns: Vector2

compareTo(Vector2 other)

public int compareTo(Vector2 other)

現在のベクトルを別のインスタンスと比較します。

Parameters:

パラメーター説明
otherVector2

Returns: int

copyFrom(Vector2 src)

public void copyFrom(Vector2 src)

Parameters:

パラメーター説明
srcVector2

create(Vector2 v)

public static FVector2 create(Vector2 v)

Vector2 を FVector2 にキャストする明示的変換演算子

Parameters:

パラメーター説明
vVector2

Returns: FVector2

cross(Vector2 v)

public double cross(Vector2 v)

2つのベクトルの外積

Parameters:

パラメーター説明
vVector2

Returns: double

div(Vector2 lhs, double rhs)

public static Vector2 div(Vector2 lhs, double rhs)

Vector2 の除算演算子

Parameters:

パラメーター説明
lhsVector2左側の値。
rhsdouble右側の値。

Returns: Vector2 - The result of division.

dot(Vector2 rhs)

public double dot(Vector2 rhs)

2つのベクトルのドット積を取得します

Parameters:

パラメーター説明
rhsVector2右側の値。

Returns: double - 二つのベクトルのドット積。

equals(Vector2 rhs)

public boolean equals(Vector2 rhs)

二つの vector2 が等しいかチェックします

Parameters:

パラメーター説明
rhsVector2右辺の値。

Returns: boolean - すべてのコンポーネントが完全に等しい場合は true。

equals(Object obj)

public boolean equals(Object obj)

二つの vector2 が等しいかチェックします

Parameters:

パラメーター説明
objjava.lang.Object比較対象のオブジェクト。

Returns: boolean - すべてのコンポーネントが完全に等しい場合は true。

getClass()

public final native Class<?> getClass()

Returns: java.lang.Class

getLength()

public double getLength()

長さを取得します。

Returns: double - 長さ。

getU()

public double getU()

Vector2 がマッピング座標として使用されている場合、U 成分を取得します。これは x 成分のエイリアスです。

Returns: double - Vector2 がマッピング座標として使用されている場合の U 成分。これは x 成分のエイリアスです。

getV()

public double getV()

Vector2 がマッピング座標として使用されている場合、V 成分を取得します。これは y 成分のエイリアスです。

Returns: double - Vector2 がマッピング座標として使用されている場合の V 成分。これは y 成分のエイリアスです。

hashCode()

public int hashCode()

Vector2 のハッシュコードを取得します

Returns: int - Vector2 のハッシュコード

mul(Vector2 lhs, double rhs)

public static Vector2 mul(Vector2 lhs, double rhs)

Vector2 の乗算演算子

Parameters:

パラメーター説明
lhsVector2左側の値。
rhsdouble右側の値。

Returns: Vector2 - The result of multiply.

mul(double lhs, Vector2 rhs)

public static Vector2 mul(double lhs, Vector2 rhs)

Vector2 の乗算演算子

Parameters:

パラメーター説明
lhsdouble左側の値。
rhsVector2右側の値。

Returns: Vector2 - The result of multiply.

normalize()

public Vector2 normalize()

このインスタンスを正規化します。

Returns: Vector2 - Normalized vector.

notify()

public final native void notify()

notifyAll()

public final native void notifyAll()

op_eq(Vector2 lhs, Vector2 rhs)

public static boolean op_eq(Vector2 lhs, Vector2 rhs)

Vector2 の等価演算子

Parameters:

パラメーター説明
lhsVector2左側の値。
rhsVector2右側の値。

Returns: boolean - すべてのコンポーネントが完全に等しい場合は true。

op_ne(Vector2 lhs, Vector2 rhs)

public static boolean op_ne(Vector2 lhs, Vector2 rhs)

Vector2 の不等価演算子

Parameters:

パラメーター説明
lhsVector2左側の値。
rhsVector2右側の値。

Returns: boolean - 2 つのベクトルが等しくない場合は true。

setU(double value)

public void setU(double value)

Vector2 がマッピング座標として使用されている場合、U 成分を設定します。これは x 成分のエイリアスです。

Parameters:

パラメーター説明
double新しい値

setV(double value)

public void setV(double value)

Vector2 がマッピング座標として使用されている場合、V 成分を設定します。これは y 成分のエイリアスです。

Parameters:

パラメーター説明
double新しい値

sub(Vector2 lhs, Vector2 rhs)

public static Vector2 sub(Vector2 lhs, Vector2 rhs)

Vector2 の減算演算子

Parameters:

パラメーター説明
lhsVector2左側の値。
rhsVector2右側の値。

Returns: Vector2 - The result of substraction.

toString()

public String toString()

現在の Vector2 を表す java.lang.String を返します。

Returns: java.lang.String - 現在の Vector2 を表す java.lang.String。

wait()

public final void wait()

wait(long arg0)

public final void wait(long arg0)

Parameters:

パラメーター説明
arg0long

wait(long arg0, int arg1)

public final void wait(long arg0, int arg1)

Parameters:

パラメーター説明
arg0long
arg1int