texture_mesh
Synopsis
map an image onto a surface, using UV coordinates generated from the surface XY coordinates
Input Port
in_field
|
Mesh
|
texture
|
Field_Unif+Dim2+Space2+Byte
|
ui_parent
|
user interface parent object
|
Parameters
Output Port
out_fld
|
Mesh+Node_Data
|
out_obj
|
output renderable object
|
Description
texture_mesh uses the texture facility of the viewer to map an image onto a surface. The texture is applied using the (X,Y) coordinates of the mesh, so that the whole image is mapped to the (X,Y) range of the mesh. By default, the lower left of the texture is applied and x min , y min , and the upper right is applied at x max , y max . See the parameters for how to change this.
Input
in_field
Field. The mesh to texture.
texture
Field_Unif+Dim2+Space2. The image to texture onto in_field.
ui_parent
A port to connect to a user interface object that contains the macro's widgets. By default, it is connected to the default user interface object in the application in which the macro is instanced. (This default connection is not drawn.)
Parameters
switch uv
UItoggle. Switch U and V (or X and Y) when generating the texture coordinates.
flip u
UItoggle. Flip U so that the texture is applied backwards in X.
flip v
UItoggle. Flip V so that the texture is applied backwards in Y.
u scale
UIslider. Scale U by this amount. The larger this value, the less space taken by the texture in X. Decreasing this value stretches the texture, increasing it compresses the texture.
v scale
UIslider. Scale V by this amount. The larger this value, the less space taken by the texture in Y. Decreasing this value stretches the texture, increasing it compresses the texture.
u shift
UIslider. Shift U by this amount. Positive shift shifts the texture to the left, negative shifts to the right.
v shift
UIslider. Scale V by this amount. Positive shift shifts the texture down, negative shifts up.
Output Port
out_fld
Mesh+Node_Data. Contains the input mesh with the texture applied.
out_obj
Renderable object corresponding to out_fld.
Example
Libraries.Examples.Visualization.Texture_Mesh
v/dv_examp/txt_mesh.v
File
v/modules.v
See also related modules