Skip to main content

convolve

Function convolve 

Source
pub(crate) fn convolve(
    src: &mut Pixmap,
    scratch: &mut Pixmap,
    width: u16,
    height: u16,
    kernel: &[f32],
    radius: u8,
    edge_mode: EdgeMode,
)
Expand description

Apply separable Gaussian convolution with logical dimensions.

Performs horizontal blur followed by vertical blur. Works with a logical view of the pixmap, using only the top-left region defined by width × height. The temp buffer is provided by the caller to avoid allocations.