remap

Function remap 

Source
pub async fn remap(
    input: &DeviceBuffer2D<u8>,
    output: &mut DeviceBuffer2D<u8>,
    map_x: &DeviceBuffer2D<f32>,
    map_y: &DeviceBuffer2D<f32>,
    stream: &Stream,
) -> Result<(), Error>
Expand description

Remaps an image using bilinear interpolation. This function expects a reference to a device buffer as inputs, and a mutable reference to a device buffer to store the output of the operation in.

This function assumes the following about the input and output images:

  • Images are in RGB format.
  • Images are in standard memory order, i.e. HWC.

§Stream ordered semantics

This function uses stream ordered semantics. It can only be guaranteed to complete sequentially relative to operations scheduled on the same stream or the default stream.

§Arguments

  • input - The on-device input image.
  • output - The on-device output image.
  • map_x - On-device X pixel map.
  • map_y - On-device Y pixel map.
  • stream - Stream to use.