texture
入力ポリゴンの輪郭に固定された「サーフェイス」上に入力ポリゴンの輪郭をストレッチして、既存のテクスチャ座標のセットを修正します。
輪郭ストレッチ処理を正常に実行するためには、ポリゴン入力に適切な輪郭が必要です。
oReturn = ModifyUVSetByContourStretching( InputObjs, TextureProjection, [ContourStretchingMethod], [MaintainAspect], [CornerPoints] ); |
作成したオペレータを含むXSICollectionを戻します。
パラメータ | タイプ | 詳細 |
---|---|---|
InputObjs | 文字列 | ポリゴンの UV テクスチャ座標の輪郭ストレッチ オペレータを適用する、入力ポリゴンのリスト。
デフォルト値: 選択したオブジェクト |
TextureProjection | 文字列 | 修正するテクスチャ空間 |
ContourStretchingMethod | siTxtContourStretchingMethod | ポリゴン クラスタの輪郭のストレッチ方法
デフォルト値: siContourStretchingWalkingOnMesh |
MaintainAspect | ブール | アスペクト比を保持するかどうかを決定
デフォルト値: False |
CornerPoints | 文字列 | 入力ポリゴンの境界上でコーナーを形成する、入力ポイントのオプション リスト。 各入力には 0 から N
個のポイントを含めることができますが、コーナーの定義に使用されるのは最大で各入力のはじめの 4 つのポイントのみです。
入力コーナーが入力ポリゴンの輪郭の一部でない場合には、無視されます。
デフォルト値: 空。 コーナーは内部で自動的に算出されます。 |
Dim l_CreatedObjects NewScene 'This example applies polygon UV contour stretching as a modifier to an existing texture space. CreatePrim "Sphere", "MeshSurface" ApplyShader , , , , siLetLocalMaterialsOverlap SIApplyShaderToCnxPoint "Image", "sphere.Material.Phong.diffuse" CreateProjection "sphere", siTxtPlanarXY, siTxtDefaultSpherical, "Texture_Support", "Texture_Projection" SetInstanceDataValue , "sphere.Material.Phong.Image.tspace_id", "Texture_Projection" SetDisplayMode "Camera", "textured" 'Create cluster to modify ActivateRaycastPolySelTool ToggleSelection "sphere.poly[19,20,27,28,35,36,43,44]", , True CreateCluster 'Modify UV by contour stretching. Contour Stretching method is default and MaintainAspect is default Corners are derived automatically set l_CreatedObjects = ModifyUVSetByContourStretching( "sphere.polymsh.cls.Polygon","sphere.polymsh.cls.Texture_Coordinates_AUTO.Texture_Projection" ) 'What was created logmessage "Created Operators: " & l_CreatedObjects |