ClusterProperty_V1.SetElementsValues

説明

このクラスタプロパティの指定されたオフセットに対応する値を設定します。

スクリプト構文

ClusterProperty_V1.SetElementsValues( [Offsets], Values );

パラメータ

パラメータ タイプ 説明
Offsets Integer 値の Array オフセットの配列。この配列が空の場合は、すべての値が考慮されます。
Value Integer値のArray(N x ValueSize) 値の配列

VBScript の例

'VBScript example

CreatePrim "Grid", "MeshSurface"

'This create a texture property containing the projected U,V,W values

CreateTextureProj

'Select the newly created property

SelectObj "grid.polymsh.cls.Texture_Coordinates_AUTO.Texture_Projection"

'The current selection contains the newly created cluster property

set mySelList = GetValue("SelectionList")

set myItem = mySelList(0)

set myClusterProp = myItem.obj

myOffsetsArray = Array( 0, 1, 2, 3 )

myValues = myClusterProp.ElementsValues( myOffsetsArray )

for i = LBound( myValues, 1 ) to UBound( myValues, 1 )

for j = LBound( myValues, 2 ) to UBound( myValues, 2 )

'Do an operation on each value. ( here v = 1 - v )

myValues( i, j ) = 1.0 - myValues( i, j )

next

next

'Now set the new values

myClusterProp.SetElementsValues myOffsetsArray, myValues

関連項目

ClusterProperty_V1.NbElements ClusterProperty_V1.ValueSize ClusterProperty_V1.SetElementsValues ClusterProperty_V1