FlipUVW

カテゴリ

texture

詳細

指定のポリゴンで、同じポイントの UVW を交換してポリゴンのテクスチャをフリップします。 ツールは四辺形のポリゴンを想定して作成されていますが、任意の形状のポリゴンで正常に動作します。

スクリプト構文

oReturn = FlipUVW( TextureProjection, SubComp, [Pivot] );

戻り値

新しく作成した FlipUVW オペレータのオブジェクト名を戻します。

パラメータ

パラメータ タイプ 詳細
TextureProjection 文字列 修正するテクスチャ プロジェクション
SubComp 文字列 フリップするポリゴンまたはタグ付きポリゴンのクラスタ
Pivot Long ポリゴンの UVW をフリップする方向

デフォルト値: 1

指定可能な値:

説明:

0 ピボットとして最初の頂点を使用します(斜めにフリップします)。
1 水平にフリップします。
2 垂直にフリップします。

VBScript の例

' Create a sphere, add texture projection, and
' assign default image to scene's material:
oSphere = CreatePrim( "Sphere", "MeshSurface" )
CreateProjection oSphere, siTxtPlanarXY, siTxtDefaultPlanarXY
SIApplyShaderToCnxPoint "Image", "Sources.Materials.DefaultLib.Scene_Material.Phong.diffuse"
' Now flip horizontally the given polygons:
oFlipuvwOp = FlipUVW( oSphere & ".polymsh.cls.Texture_Coordinates_AUTO.Texture_Projection", oSphere & ".poly[12,20,44,52]", 1 )
LogMessage "New Flip UVW operator: " & oFlipuvwOp
SelectGeometryComponents oSphere & ".poly[12,20,44,52]"
' View the results:
SetDisplayMode "Camera", "textured"
' Running this script should log the following:
' ---------------------------------------------
'INFO : "New Flip UVW operator: sphere.polymsh.cls.Texture_Coordinates_AUTO.Texture_Projection.Flipuvw"

関連項目

CycleUVW