PolygonBuilder

Inheritance: java.lang.Object

public final class PolygonBuilder

ポリゴンを構築するためのヘルパークラスです Mesh Example:

Mesh mesh = new Mesh();
  PolygonBuilder builder = new PolygonBuilder(mesh);
  builder.begin();
  builder.addVertex(0);
  builder.addVertex(1);
  builder.addVertex(2);
  builder.end();

等しい :

Mesh mesh = new Mesh();
  int[] indices = new int[] {0, 1, 2};
  mesh.createPolygon(indices);

すべてのインデックスが使用可能な場合は、Mesh が推奨されます。そうでなければ、PolygonBuilder の方が適しています。

コンストラクタ

コンストラクタ説明
PolygonBuilder(Mesh mesh)新しい PolygonBuilder クラスのインスタンスを初期化します。

メソッド

メソッド説明
addVertex(int index)ポリゴンに頂点インデックスを追加します
begin()新しいポリゴンの追加を開始します
end()ポリゴンの作成を完了します
equals(Object arg0)
getClass()
hashCode()
notify()
notifyAll()
toString()
wait()
wait(long arg0)
wait(long arg0, int arg1)

PolygonBuilder(Mesh mesh)

public PolygonBuilder(Mesh mesh)

新しい PolygonBuilder クラスのインスタンスを初期化します。

Parameters:

パラメーター説明
meshMeshポリゴンを構築するメッシュです。

addVertex(int index)

public void addVertex(int index)

ポリゴンに頂点インデックスを追加します

Parameters:

パラメーター説明
インデックスint

begin()

public void begin()

新しいポリゴンの追加を開始します

end()

public void end()

ポリゴンの作成を完了します

equals(Object arg0)

public boolean equals(Object arg0)

Parameters:

パラメーター説明
arg0java.lang.Object

Returns: boolean

getClass()

public final native Class<?> getClass()

Returns: java.lang.Class

hashCode()

public native int hashCode()

Returns: int

notify()

public final native void notify()

notifyAll()

public final native void notifyAll()

toString()

public String toString()

Returns: 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