Skip to content

Displace

Brief Description

Displace the source image according to a Displacement Map image. The Displacement Map indicates for each pixel an offset where to move the pixels in the output image. The red channel of the map is used as an offset to the X coordinate of the pixel while the green channel of the map is used as an offset to the Y coordinate. If Use Map Alpha is checked, the displacement map red and green channels are multiplied by the alpha channel of the displacement map. This is useful when the red and green channels may contain non zero values where alpha is zero. The values of the pixels of the displacement map are assumed to be normalized in the range [0,1]:

  • A value of 1 will offset the pixel by half the size of the source image
  • A value of 0 will offfset the pixel by minus half of the size
  • A value of 0.5 will keep the pixel at its original position

Controls

Parameter / Script Name Type Default Function
Enabled / enabled Boolean On
Displacement Map / uv Image - This effect will read the first 2 channels (i.e: red and green) for the X and Y coordinates respectively
Red / process_red Boolean On Enable the red channel in output. Otherwise if there's a source the content of the main source is returned instead, else 0
Green / process_green Boolean On Enable the green channel in output. Otherwise if there's a source the content of the main source is returned instead, else 0
Blue / process_blue Boolean On Enable the blue channel in output. Otherwise if there's a source the content of the main source is returned instead, else 0
Alpha / process_alpha Boolean On Enable the alpha channel in output. Otherwise if there's a source the content of the main source is returned instead, else 0
Amount / scale Float 2D 10, 10 A scale factor applied to the uv value at each pixel of the uv map
Offset / offset Float 2D 0, 0 An offset subtracted from the u value at each pixel of the uv map. This is applied after scale
Wrap U / u_wrap Choice Black How the source image is accessed when the X coordinate is out of bounds
- Black
- Clamp to edge
- Repeat
- Mirror
Wrap V / v_wrap Choice Black How the source image is accessed when the Y coordinate is out of bounds
- Black
- Clamp to edge
- Repeat
- Mirror
Warp Method / method Choice Backward The algorithm chosen to apply the warp. You may need to adjust the displacement map direction by multiplying the Scale parameter by -1
- Forward
- Backward
Supersampling / supersampling Choice x2 The supersampling factor. Higher means more quality and antialiasing but slower to render
- x1
- x2
- x4
- x8
- x16
Use Map Alpha / multiply_uv_by_source_alpha Boolean On When checked, the displacement map red and green channels are multiplied by the alpha channel of the displacement map. This is useful when the red and green channels may contain non zero values where alpha is zero.
Depth Map / depth_map Image - If linked to a generator and Method is set to Forward, the red channel is used to give the pixels a depth to control pixel z order. If not linked, the default order is the vertex order, i.e: from left to right, bottom to top.
Source Outside / forward_fill_outside_with_source Boolean Off If Method is set to Forward, fills region not affected by the displacement by the original source image
Fitting / uv_fit Choice No Fitting
- No Fitting
- Fit Source To UV-Map
- Fit UV-Map To Source
Bounding Box / rod_mode Choice Composition Format
- Unbounded
- Same as Source
- Composition Format
Mask / mask Image -
Mix / mix_with_source Float 1 Dissolves between the original image at 0 and the image with the effect applied at 1