convolve-image

Crates.ioconvolve-image
lib.rsconvolve-image
version0.4.0
sourcesrc
created_at2024-04-08 14:27:32.837793
updated_at2024-05-03 02:26:03.543652
descriptionA small library to perform convolution operations on images with arbitrarily-sized separable kernels
homepagehttps://github.com/anshap1719/convolve-image
repositoryhttps://github.com/anshap1719/convolve-image
max_upload_size
id1200400
size22,806
Anshul Sanghi (anshap1719)

documentation

README

Image Convolution Using Separable Kernel

This project provides an implementation convolution on images using separable kernels of arbitrary size. The library is aimed to provide a fast implementation with 0 dependencies other than image-rs.

Usage

use convolve_image::convolve::Convolution;
use convolve_image::kernel::SeparableKernel;

fn convolve_image() {
    let image = image::open("./sample.jpg").unwrap();
    let image = image.to_rgb32f();
    image.convolve(SeparableKernel::new([1. / 4., 1. / 2., 1. / 4.]), 1);
}

Installation

To use this library in your Rust project, add the following to your Cargo.toml file:

[dependencies]
convolve-image = "0.1.0"
Commit count: 7

cargo fmt