Safe Haskell | None |
---|---|
Language | Haskell98 |
Filters
- lp1 :: Sig -> Sig -> Sig
- hp1 :: Sig -> Sig -> Sig
- lp :: Sig -> Sig -> Sig -> Sig
- hp :: Sig -> Sig -> Sig -> Sig
- bp :: Sig -> Sig -> Sig -> Sig
- br :: Sig -> Sig -> Sig -> Sig
- alp :: Sig -> Sig -> Sig -> Sig
- bp2 :: Sig -> Sig -> Sig -> Sig
- br2 :: Sig -> Sig -> Sig -> Sig
- blp :: Sig -> Sig -> Sig
- bhp :: Sig -> Sig -> Sig
- bbp :: Sig -> Sig -> Sig -> Sig
- bbr :: Sig -> Sig -> Sig -> Sig
- type ResonFilter = Sig -> Sig -> Sig -> Sig
- type FlatFilter = Sig -> Sig -> Sig
- filt :: Int -> ResonFilter -> ResonFilter
- flatFilt :: Int -> FlatFilter -> FlatFilter
- mlp :: Sig -> Sig -> Sig -> Sig
- mlp2 :: Sig -> Sig -> Sig -> Sig
- mlp3 :: Sig -> Sig -> Sig -> Sig
- lp18 :: Sig -> Sig -> Sig -> Sig -> Sig
- formant :: ResonFilter -> [(Sig, Sig)] -> Sig -> Sig
- singA :: Sig -> Sig
- singO :: Sig -> Sig
- singE :: Sig -> Sig
- singU :: Sig -> Sig
- singO2 :: Sig -> Sig
- smooth :: Sig -> Sig -> Sig
- slide :: Sig -> Sig -> Sig
- alp1 :: Sig -> Sig -> Sig -> Sig
- alp2 :: Sig -> Sig -> Sig -> Sig
- alp3 :: Sig -> Sig -> Sig -> Sig
- alp4 :: Sig -> Sig -> Sig -> Sig
- ahp :: Sig -> Sig -> Sig
- mvchpf :: Sig -> Sig -> Sig
- mvclpf1 :: Sig -> Sig -> Sig -> Sig
- mvclpf2 :: Sig -> Sig -> Sig -> Sig
- mvclpf3 :: Sig -> Sig -> Sig -> Sig
- mvclpf4 :: Sig -> Sig -> Sig -> Sig
Documentation
Arguemnts are inversed to get most out of curruing. First come parameters and the last one is the signal.
First order filters
lp1 :: Sig -> Sig -> Sig Source
First order low pass filter (tone in Csound, 6 dB)
lp1 centerFreq asig
hp1 :: Sig -> Sig -> Sig Source
First order high pass filter (atone in Csound, 6 dB)
hp1 centerFreq asig
Simple filters
bp2 :: Sig -> Sig -> Sig -> Sig Source
Resonance band pass filter (yet another implementation, it's reson in Csound)
bp2 centerFreq q asig
br2 :: Sig -> Sig -> Sig -> Sig Source
Resonance band reject filter (yet another implementation, it's areson in Csound)
br2 centerFreq q asig
Butterworth filters
Filter order
type FlatFilter = Sig -> Sig -> Sig Source
Filter without a resonance.
f centerFreq q asig
filt :: Int -> ResonFilter -> ResonFilter Source
Applies a filter n-times. The n is given in the first rgument.
flatFilt :: Int -> FlatFilter -> FlatFilter Source
Applies a flat filter (without resonance) n-times. The n is given in the first rgument.
Specific filters
Moog filters
mlp2 :: Sig -> Sig -> Sig -> Sig Source
Another implementation of moog low pass filter (it's moogladder in Csound).
The arguments have are just like in the mlp
filter.
lp18 :: Sig -> Sig -> Sig -> Sig -> Sig Source
Low pass filter 18 dB with built in distortion module.
lp18 distortion centerFreq resonance asig
- distortion's range is 0 to 1
- resonance's range is 0 to 1
Formant filters
formant :: ResonFilter -> [(Sig, Sig)] -> Sig -> Sig Source
Formant filter.
formant bandPassFilter formants asig
It expects a band pass filter, a list of formants and processed signal. The signal is processed with each filter the result is a sum of all proceessed signals. Formant filters are used to mimic the vocalization of the sound.
Making the smooth lines
smooth :: Sig -> Sig -> Sig Source
Produces smooth transitions between values in the signals. The first value defines a duration in seconds for a transition from one value to another in piecewise constant signals.
slide :: Sig -> Sig -> Sig Source
Makes slides between values in the signals. The first value defines a duration in seconds for a transition from one value to another in piecewise constant signals.
Analog filters
Requires Csound 6.07 or higher
alp1 :: Sig -> Sig -> Sig -> Sig Source
Analog-like low-pass filter
alpf1 centerFrequency resonance asig
alp2 :: Sig -> Sig -> Sig -> Sig Source
Analog-like low-pass filter
alpf2 centerFrequency resonance asig
alp3 :: Sig -> Sig -> Sig -> Sig Source
Analog-like low-pass filter
alpf3 centerFrequency resonance asig
alp4 :: Sig -> Sig -> Sig -> Sig Source
Analog-like low-pass filter
alpf4 centerFrequency resonance asig
Low level analog filters
mvchpf :: Sig -> Sig -> Sig Source
Moog ladder lowpass filter.
Moogladder is an new digital implementation of the Moog ladder filter based on the work of Antti Huovilainen, described in the paper "Non-Linear Digital Implementation of the Moog Ladder Filter" (Proceedings of DaFX04, Univ of Napoli). This implementation is probably a more accurate digital representation of the original analogue filter.
asig moogladder ain, kcf, kres[, istor]
csound doc: http://www.csounds.com/manual/html/moogladder.html
Emulator of analog high pass filter.
mvchpf asig xfreq