インタフェース > コア インタフェース > OpenEdgesxView チェック |
OpenEdges コア インタフェースは、開いたエッジの xView チェッカーと相互作用するためのメソッドを公開しています。
3ds Max 2010 以降 で使用可能です。
プロパティ:
プロパティは公開していません。
メソッド:
<enum>OpenEdges.Check <time>time <node>nodeToCheck <&index array>results Check enums: {#Failed|#Vertices|#Edges|#Faces} results is In and Out parameter
開いたエッジの xView チェックを、指定された時間に指定されたノードに対して実行し、その結果を 3 番目の引数として参照渡しされた配列に返します。
このメソッドは常に #edges enum を返します。これは、開いたエッジのチェックによって結果の配列に書き込まれる値は、常に開いたエッジのインデックスを表すためです。
<bool>OpenEdges.hasPropertyDlg()
xView チェッカーがプロパティ ダイアログ ボックスを実装している場合は true、実装していない場合は false を返します。
開いたエッジのチェッカーでは、常に false が返されます。
<void>OpenEdges.showPropertyDlg()
実装されている場合は、xView チェッカーのプロパティ ダイアログ ボックスを表示します。
開いたエッジのチェッカーでは、このメソッドは何もしません。
例: |
以下のコードでは、5x5 のセグメントを持つ平面を作成し、これを編集可能ポリゴンに集約した後、内側のポリゴンを T 字型に削除しています。これにより開いたエッジの数が増えます。 |
thePlane = plane width:100 length:100 widthsegs:5 lengthsegs:5 --> $Plane:Plane01 @ [0.000000,0.000000,0.000000] convertTo thePlane Editable_Poly --> $Editable_Poly:Plane01 @ [0.000000,0.000000,0.000000] polyop.deleteFaces thePlane #{7..9,13,18} --> OK |
![]()
|
以下の OpenEdges.check()メソッドの呼び出しでは、開いたエッジが返されます。ビューポートで開いたエッジのチェッカーがアクティブになっている必要はありません。これは、MAXScript コード内で、開いたエッジのインデックスを配列またはビット配列に取得する目的で使用できます。 |
theResults = #() --we need an array to store the results in --> #() --We call the method by passing the time to check at, --the object to check and the by-reference array to store --the results in. The return result of the method itself --will be #Edge because the method operates on edges --and the content of theResults array should be threated --as edge indices: resultType = openEdges.Check currentTime thePlane &theResults --> #Edges --If we would print out the content of the array variable as bitarray, --it will contain the indices of the open edges as bits set to true: theResults as bitarray --> #{1, 4..5, 7..8, 10..11, 13, 15..17, 19..22, 24..25, 29..30, 34..35, 39..41, 45..47, 49, 51, 53, 55..56} --We can check the number of returned edge indices - it will --be the same as the count reported by the Open Edges Checker --in the Viewport: theResults.count --> 32 --We could easily select the open edges now: polyOp.setEdgeSelection thePlane theResults --> OK |