cute_dsp/
lib.rs

1//! # Signalsmith DSP
2//!
3//! A Rust port of the Signalsmith DSP C++ library, providing various DSP (Digital Signal Processing)
4//! algorithms for audio and signal processing.
5//!
6//! ## Features
7//!
8//! - **FFT**: Fast Fourier Transform implementation optimized for sizes that are products of 2^a * 3^b
9//! - **Filters**: Biquad filters with various configurations (lowpass, highpass, bandpass, etc.)
10//! - **Delay Lines**: Efficient delay line implementation with interpolation
11//! - **Curves**: Cubic curve interpolation
12//! - **Windows**: Window functions for spectral processing
13//! - **Envelopes**: LFOs and envelope generators
14//! - **Linear Algebra**: Expression template system for efficient vector operations
15//! - **no_std Support**: Can be used in environments without the standard library
16
17#![cfg_attr(not(feature = "std"), no_std)]
18
19#[cfg(feature = "alloc")]
20extern crate alloc;
21
22#[cfg(feature = "wasm")]
23use wasm_bindgen::prelude::*;
24
25// Re-export modules
26pub mod common;
27pub mod curves;
28pub mod perf;
29pub mod mix;
30pub mod rates;
31pub mod windows;
32pub mod linear;
33
34pub mod envelopes;
35
36pub mod spectral;
37
38pub mod stft;
39pub mod delay;
40pub mod fft;
41pub mod filters;
42pub mod stretch;
43pub mod convolver;
44pub mod phase_rotation;
45
46pub mod spacing;
47
48#[cfg(feature = "wasm")]
49mod wasm_bindings;
50
51#[cfg(feature = "wasm")]
52pub use wasm_bindings::*;
53
54#[cfg(feature = "wasm")]
55#[wasm_bindgen]
56pub fn version() -> String {
57    env!("CARGO_PKG_VERSION").to_string()
58}