Vizard 8 » Command Index » Vizard objects » node3d » <node3d>.texmat
8.1

<node3d>.texmat

Perform a transformation on the objects texture coordinates

<node3d>.texmat(  
transform  
node = ''  
unit = 0  
autoScale = False  
op = viz.OP_DEFAULT  
)  
transform
This can be a list of 16 numbers representing a 4x4 matrix or a <vizmat>.Transform object.
node = ''
Name of sub-node to apply changes to
unit = 0
The texture unit to apply the changes to, or viz.AUTO_COMPUTE to apply changes to all available texture units.
autoScale = False
If True, the texture matrix will automatically scale the coordinates to match the size of any texture rectangle texture being applied.
op = viz.OP_DEFAULT
Can be viz.OP_DEFAULT to use the nodes default op mode or a combination of the following values:

Op modes

viz.OP_TRAVERSE

When performing an operation on a node, traverse the entire subgraph and process all subnodes as well. This is the default value.

viz.OP_OVERRIDE

When applying attributes, have them override attributes of subnodes.

viz.OP_ROOT

When performing an operation on the node, start at the root transform of the node, instead of the model. Processing the root will include all child Vizard nodes.

Remarks

This command will apply the transform to the objects texture coordinates.

Return Value

None

Example

#Create a transform that translates 0.1 along the x axis
x = viz.Transform()
x.setTrans(0.1,0,0)

#Translate the grounds texture coordinates by 0.1 along the x axis
ground = viz.add('tut_ground.wrl')
ground.texmat(x)