class RemiAudio::DSP::ParaEQ
- RemiAudio::DSP::ParaEQ
- Reference
- Object
Overview
A mono parametric EQ.
The first band is always a low shelf, and the last band is always a high shelf. The others are all normal peaking bands.
Defined in:
remiaudio/dsp/paraeq.crConstant Summary
-
DEFAULT_HIGH_SHELF_FREQ =
15000.0
-
The default cutoff frequency for the high shelf, in Hertz.
-
DEFAULT_HIGH_SHELF_WIDTH =
0.7071067811865475
-
The default bandwidth for the high shelf, in octaves.
-
DEFAULT_LOW_SHELF_FREQ =
80.0
-
The default cutoff frequency for low shelf, in Hertz.
-
DEFAULT_LOW_SHELF_WIDTH =
0.7071067811865475
-
The default bandwidth for band 0, in octaves.
-
DEFAULT_PEAKING_FREQ =
500.0
-
The default cutoff frequency for the peaking bands, in Hertz.
-
DEFAULT_PEAKING_Q =
1.0
-
The default bandwidth for the peaking bands, as a Q value.
Constructors
-
.new(numBands, newSampleRate)
Creates a new parametric EQ.
Instance Method Summary
-
#active=(active : Bool)
When true, this equalizer will process audio, otherwise it will pass any audio through unmodified.
-
#active? : Bool
When true, this equalizer will process audio, otherwise it will pass any audio through unmodified.
-
#plot(pt : PlotType) : String
Generates a string that can be passed to a program to plot this equalizer on a graph.
-
#postGain : Float64
The amount of gain to apply after the EQ, in decibels.
-
#postGain=(value : Float64) : Nil
The amount of gain to apply after the EQ, in decibels.
-
#process(sample : Float64) : Float64
Processes a single sample of audio with the equalizer, returning a processed sample.
-
#process(sample : Float32) : Float32
Processes a single sample of audio with the equalizer, returning a processed sample.
-
#process(block : Array(Float64) | Slice(Float64)) : Nil
Processes a block of audio with the equalizer.
-
#reset : Nil
Resets all bands in the equalizer.
-
#sampleRate : Float64
The sample rate of the equalizer.
-
#setBand(band : Int, freq : Float64, gain : Float64, width : Float64) : Nil
Sets the frequency/band/width for the given band.
Constructor Detail
Creates a new parametric EQ. Bands 1 through numBands-2 are peaking bands, while bands 0 and numBands-1 are the shelves. numBands must be at least 2, and includes the lowshelf and highshelf.
Instance Method Detail
When true, this equalizer will process audio, otherwise it will pass any audio through unmodified.
When true, this equalizer will process audio, otherwise it will pass any audio through unmodified.
Generates a string that can be passed to a program to plot this equalizer
on a graph. The PlotType
dictates what kind of script is generated.
Processes a single sample of audio with the equalizer, returning a processed sample.
Processes a single sample of audio with the equalizer, returning a processed sample.
Processes a block of audio with the equalizer.
Sets the frequency/band/width for the given band.
If freq
is greater than 49.9% of the sampling frequency, that band will
be disabled.