script (MEL) |
Only available in
MEL |
textureDisplacePlane
|
In categories: Rendering |
Go to: Synopsis. Return value. MEL
examples.
textureDisplacePlane resolution
textureName
This mel procedure creates a poly plane with an expression to
offset the uvs based on an input surface texture or oceanShader
node. The input texture may be modified and the plane will
interactively update. The generated expression provides an example
of how one could use the colorAtPoint command to create a
displacement mapping effect. Note that for preview uses the
heightField node is more efficient for this general task, although
it does not modify geometry that can be rendered or output. If one
uses this for an ocean shader, the mapping is determined by the
position of the plane, such that translating the plane moves it
over the stationary ocean displacement. For surface textures the
mapping is the same as the texture swatch( uv 0-1). If the defined
resolution is greater than 20 the expression uses setAttr calls to
update the points on the polyset. Otherwise direct node connections
are created from the expression to each cv, which plays back faster
but takes longer to set up the expression.
None
Variable Name |
Variable Type |
Description |
|
|
None. |
// Create a noise texture
createRenderNodeCB -as2DTexture "" noise "";
// Result: noise1 //
textureDisplacePlane 10 noise1;
// Creates 10x10 poly plane with noise displacement expression //