NurbsSurface.Set operator

説明

NurbsSurface の完全なデータ記述を設定します。このメソッドはスクリプトオペレータからのみ使用できます。このメソッドをクラスタのあるオブジェクトに使用してトポロジを変更した場合は、クラスタの更新はユーザが実行する必要があります。スクリプトオペレータでないオペレータの場合は、このプロパティは、オブジェクトがフリーズされている場合にのみ設定できます。

スクリプト 構文

NurbsSurface.Set( ControlPoints, [UKnots], [VKnots], [UClosed], [VClosed], [UDegree], [VDegree], [UParameterization], [VParameterization], [NurbsFormat] );

パラメータ

パラメータ タイプ 詳細
ControlPoints 3DArray コントロールポイントは3D 配列に格納されます。

配列は、4 * V ControlPoint の数 * U ControlPoint の数です。
UKnots DoubleArray U方向のノット値の配列
VKnots DoubleArray V方向のノット値の配列
UClosed Boolean NURBS サーフェイスが U方向で閉じられているかどうかを指定します。
VClosed Boolean NURBS サーフェイスがV方向で閉じられているかどうかを指定します。
UDegree Long NURBS サーフェイスの U方向の次数
VDegree Long NURBS サーフェイスの V方向の次数
UParameterization siKnotParameterization NURBS サーフェイスの U方向のパラメータ配置方法
VParameterization siKnotParameterization NURBS サーフェイスの V方向のパラメータ配置方法
NurbsFormat siNurbsFormat NURBs のデータ形式を指定します。

デフォルト値:siSINurbs

VBScript の例

Dim lDegree(2), bClosed(2), eParameterization(2), aControlPoints, aKnots(2)
set oRoot = Application.activeproject.activescene.root
set oSphere = oRoot.AddGeometry( "Sphere", "NurbsSurface" )
FreezeObj oSphere
oSphere.ActivePrimitive.Geometry.Surfaces(0).Get _              
        siSINurbs, _
        aControlVertex, _
        aKnots(siUDirection),aKnots(siVDirection) , _
        bClosed(siUDirection),bClosed(siVDirection), _
        lDegree(siUDirection),lDegree(siVDirection), _
        eParameterization(siUDirection),eParameterization(siVDirection)
for i = lbound(aControlVertex,3) to ubound(aControlVertex,3)
        for j = lbound(aControlVertex,2) to ubound(aControlVertex,2)
                        aControlVertex(0,j,i) = aControlVertex(0,j,i) + 1
                        aControlVertex(1,j,i) = aControlVertex(1,j,i) + 1
                        aControlVertex(2,j,i) = aControlVertex(2,j,i) + 1
                        aControlVertex(3,j,i) = aControlVertex(3,j,i) + 1
        next
next
' Create new nurbs surface list from arc data.
        oSphere.ActivePrimitive.Geometry.Surfaces(0).Set _
        aControlVertex, _
        aKnots(siUDirection),aKnots(siVDirection), _
        bClosed(siUDirection),bClosed(siVDirection), _
        lDegree(siUDirection),lDegree(siVDirection), _
        eParameterization(siUDirection),eParameterization(siVDirection), _
        siSINurbs