[][src]Function opencv::ximgproc::anisotropic_diffusion

pub fn anisotropic_diffusion(
    src: &dyn ToInputArray,
    dst: &mut dyn ToOutputArray,
    alpha: f32,
    k: f32,
    niters: i32
) -> Result<()>

Performs anisotropic diffusion on an image.

The function applies Perona-Malik anisotropic diffusion to an image. This is the solution to the partial differential equation:

block formula

Suggested functions for c(x,y,t) are:

block formula

or

block formula

Parameters

  • src: Source image with 3 channels.
  • dst: Destination image of the same size and the same number of channels as src .
  • alpha: The amount of time to step forward by on each iteration (normally, it's between 0 and 1).
  • K: sensitivity to the edges
  • niters: The number of iterations