Package processing.sound
Class BandPass
- Record Components:
parent
- PApplet: typically use "this"
This is a band pass filter.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
bw
(float bw) Sets the bandwidth of this BandPass filter.void
freq
(float freq) Sets the center frequency of the filter.void
process
(SoundObject input, float freq, float bw) Start applying this bandpass filter to an input signal.void
res
(float q) Sets a fixed Q factor for this filter.void
set
(float freq, float bw) Sets frequency and bandwidth of the filter with one method.Methods inherited from class processing.sound.Effect
isProcessing, process, stop
-
Constructor Details
-
BandPass
-
-
Method Details
-
bw
public void bw(float bw) Sets the bandwidth of this BandPass filter.- Parameters:
bw
- the filter bandwidth in Hertz- See Also:
-
BandPass#res()
-
res
public void res(float q) Sets a fixed Q factor for this filter. If you want to specify a fixed bandwidth for this bandpass filter (in Hertz) that is maintained even as the center frequency of the filter changes, usebw(float)
instead.- Overrides:
res
in classFilter<FilterBandPass>
- Parameters:
q
- the desired Q factor, a value between 0.1 and 10- See Also:
-
BandPass#bw()
-
freq
public void freq(float freq) Sets the center frequency of the filter.- Overrides:
freq
in classFilter<FilterBandPass>
- Parameters:
freq
- the center frequency in Hertz
-
process
Start applying this bandpass filter to an input signal.- Overrides:
process
in classFilter<FilterBandPass>
- Parameters:
input
- the sound source to filterfreq
- the center frequency in Hertzbw
- the filter bandwidth in Hertz
-
set
public void set(float freq, float bw) Sets frequency and bandwidth of the filter with one method.- Overrides:
set
in classFilter<FilterBandPass>
- Parameters:
freq
- the center frequency in Hertzbw
- the filter bandwidth in Hertz
-