vertex

ポリゴンメッシュ形状の一つの頂点の操作に使用する。


xshade
shape
vertex

メソッド一覧

remove 頂点を削除する

プロパティ一覧

active 選択状態
active_order 選択した順番の番号
normal 頂点の法線
position 座標位置
skin 頂点のスキン




xshade.scene().active_shape().vertex(0)(選択形状の頂点の取得)のように頂点を取得して使用する。

メソッド詳細

remove

頂点を削除する。

xshade.scene().active_shape().vertex(0).remove()

プロパティ詳細

active

選択状態。

  • 取得
  • 設定

型 :
  bool
設定する場合、図面か形状を更新しないと変更がすぐに反映されない。

#0番の頂点を選択状態にして形状を更新する
xshade.scene().active_shape().vertex(0).active = True
xshade.scene().active_shape().update()

active_order

選択した順番の番号。

  • 取得
  • 設定

型 :
  int

print xshade.scene().active_shape().vertex(0).active_order

normal

頂点の法線。

  • 取得
  • 設定

型 :
  float3
setup_normalを設定したポリゴンメッシュからのみ取得可能。

print xshade.scene().active_shape().vertex(0).normal

position

座標位置。

  • 取得
  • 設定

型 :
  vec3

print xshade.scene().active_shape().vertex(0).position

skin

頂点のスキン。

  • 取得
  • 設定

型 :
  skinオブジェクト
参照 :
  skin

#0番の頂点のスキンのバインドの数を出力する
print xshade.scene().active_shape().vertex(0).skin.number_of_binds