displace_mesh: Displace a Mesh
Description
Displace a Mesh
Usage
displace_mesh(
mesh,
displacement_texture,
displacement_scale = 1,
displacement_vector = FALSE,
id = NA,
verbose = TRUE
)
Arguments
- mesh
The mesh.
- displacement_texture
Image or matrix/array that will be used to displace the mesh
- displacement_scale
Default 1
. Intensity of the displacement effect.
Higher values result in greater displacement.
- displacement_vector
Default FALSE
. Whether to use vector displacement.
If TRUE
, the displacement texture is interpreted as providing a 3D displacement vector.
Otherwise, the texture is interpreted as providing a scalar displacement.
- id
Default NA
(all shapes). The shape index to have new normals calculated.
- verbose
Default TRUE
. Whether to print displacement texture information.
Examples
Run this codeif(run_documentation()) {
#Let's construct a mesh from the volcano dataset
}
Run the code above in your browser using DataLab