leptonica 0.1.0

Rust port of Leptonica image processing library
Documentation
//! leptonica-filter - Image filtering operations
//!
//! This crate provides image filtering operations including:
//!
//! - Convolution with arbitrary kernels
//! - Blur operations (box blur, Gaussian blur)
//! - Edge detection (Sobel, Laplacian)
//! - Image enhancement (sharpening, unsharp masking, emboss)
//! - Bilateral filtering (edge-preserving smoothing)
//! - Rank filtering (median, min, max filters)
//! - Adaptive mapping (background normalization, contrast normalization)

pub mod adaptmap;
pub mod bilateral;
pub mod block_conv;
pub mod convolve;
pub mod edge;
pub mod enhance;
mod error;
pub mod kernel;
pub mod rank;
pub mod windowed;

pub use error::{FilterError, FilterResult};
pub use kernel::Kernel;

// Re-export commonly used functions
pub use adaptmap::{
    BackgroundNormOptions, ContrastNormOptions, EdgeFilterType, FlexNormOptions,
    apply_inv_background_gray_map, apply_inv_background_rgb_map, apply_variable_gray_map,
    background_norm, background_norm_flex, background_norm_gray_array,
    background_norm_gray_array_morph, background_norm_morph, background_norm_rgb_arrays,
    background_norm_rgb_arrays_morph, background_norm_simple, background_norm_to_1_min_max,
    clean_background_to_white, contrast_norm, contrast_norm_simple, convert_to_8_min_max,
    extend_by_replication, fill_map_holes, get_background_gray_map, get_background_gray_map_morph,
    get_background_rgb_map, get_background_rgb_map_morph, get_inv_background_map,
    global_norm_no_sat_rgb, global_norm_rgb, smooth_connected_regions, threshold_spread_norm,
};
pub use bilateral::{
    bilateral, bilateral_exact, bilateral_gray, bilateral_gray_exact, block_bilateral_exact,
    make_range_kernel,
};
pub use block_conv::{blockconv, blockconv_accum, blockconv_gray, blockconv_gray_unnormalized};
pub use convolve::{
    add_gaussian_noise, blockrank, blocksum, box_blur, census_transform, convolve, convolve_color,
    convolve_gray, gaussian_blur,
};
pub use edge::{
    EdgeOrientation, emboss, laplacian_edge, sharpen, sobel_edge, unsharp_mask,
    unsharp_masking_fast, unsharp_masking_gray_fast,
};
pub use enhance::{
    TrcLut, color_shift_rgb, contrast_trc, contrast_trc_masked, contrast_trc_pix, darken_gray,
    equalize_trc, equalize_trc_pix, gamma_trc, gamma_trc_masked, gamma_trc_pix,
    gamma_trc_with_alpha, measure_saturation, modify_brightness, modify_hue, modify_saturation,
    mult_constant_color, mult_matrix_color, trc_map, trc_map_general, unsharp_masking,
    unsharp_masking_gray,
};
pub use rank::{
    MinMaxOp, max_filter, median_filter, min_filter, rank_filter, rank_filter_color,
    rank_filter_gray, scale_gray_min_max, scale_gray_rank_cascade, scale_gray_rank2,
};
pub use windowed::{
    WindowedStatsResult, mean_square_accum, windowed_mean, windowed_mean_square, windowed_stats,
    windowed_variance,
};