Pastes the UVs that are in the clipboard onto the specified texture projection. If the UVs are copied from one texture projection and pasted onto another then the texture coordinates are set based on the indices of the source selection. If they are pasted on the same texture projection then they are scaled and translated so their bounding boxes match (if possible).
PasteUVW( TextureProjection, [SubComp], [PasteUVsMode] ); |
Parameter | Type | Description |
---|---|---|
TextureProjection | String | The target texture projection. |
SubComp | String | The target cluster of sampled points or tagged sampled points |
PasteUVsMode | siPasteUVsMode | This argument controls how UVs copied from one object are
pasted onto a different object with the same topology. The default behaviour (siDefaultPasteUVsMode) tries to match UVs based on vertex and polygon ordering. If that fails the source UV indices and then the target UV indices will be used in that order. Specifying siPasteUVsUsingSourceIndices or siPasteUVsUsingTargetIndices will paste UVs using source or target indices only. Default Value: siDefaultPasteUVsMode |
' This example demonstrates how to copy the UVs from, ' one object to an other. NewScene , false ' create a sphere and generate a texture projection for it ' using the GenerateUniqueUVs command. CreatePrim "Sphere", "MeshSurface", "Sphere1" GenerateUniqueUVs "Sphere1", "Texture_Projection" MakeLocal "Sphere1.Scene_Material", siDefaultPropagation BlendInTextureLayersInsp , , 2, True, siReplaceAndNoBlendInTextureLayers Translate , 9.0, 0.0, 0.0, siRelative, siView, siObj, siXYZ, , , , , , , , , , 0 ' create a second sphere and generate a default cubic projection ' for it CreatePrim "Sphere", "MeshSurface", "Sphere2" CreateProjection "Sphere2", siTxtUV, siTxtDefaultCubic, "Texture_Support", "Texture_Projection", True, siRelDefault MakeLocal "Sphere2.Scene_Material", siDefaultPropagation BlendInTextureLayersInsp , , 2, True, siReplaceAndNoBlendInTextureLayers ' now, copy the UVs from the Sphere1 to the Sphere2 CopyUVW "Sphere1.polymsh.cls.Texture_Coordinates_AUTO.Texture_Projection" PasteUVW "Sphere2.polymsh.cls.Texture_Coordinates_AUTO.Texture_Projection" |