@@ -129,7 +129,7 @@ pipeline. Both formats use transposed direct form 2.
Low-Pass, High-Pass and Band-Pass Filters
-----------------------------------------
APIs for low-pass, high-pass and band-pass filtering has been added. By themselves they are second order filters, but can be extended to higher orders by
chaining them together. Low-pass, high-pass and band-pass filtering is achieved via the `ma_lpf2`, `ma_hpf` and `ma_bpf` APIs respectively. Since these filters
chaining them together. Low-pass, high-pass and band-pass filtering is achieved via the `ma_lpf2`, `ma_hpf2` and `ma_bpf` APIs respectively. Since these filters
are just biquad filters, they support both 32-bit floating point and 16-bit signed integer formats.
...
...
@@ -1000,7 +1000,7 @@ and will result in an error.
Low-Pass, High-Pass and Band-Pass Filtering
===========================================
Low-pass, high-pass and band-pass filtering is achieved with the `ma_lpf2`, `ma_hpf` and `ma_bpf` APIs respective. Low-pass filter example:
Low-pass, high-pass and band-pass filtering is achieved with the `ma_lpf2`, `ma_hpf2` and `ma_bpf` APIs respective. Low-pass filter example:
@@ -1035,7 +1035,7 @@ If you need to change the configuration of the filter, but need to maintain the
useful if you need to change the sample rate and/or cutoff frequency dynamically while maintaing smooth transitions. Note that changing the format or channel
count after initialization is invalid and will result in an error.
The example code above is for low-pass filters, but the same applies for high-pass and band-pass filters, only you should use the `ma_hpf` and `ma_bpf` APIs
The example code above is for low-pass filters, but the same applies for high-pass and band-pass filters, only you should use the `ma_hpf2` and `ma_bpf` APIs
instead.
...
...
@@ -1702,19 +1702,19 @@ typedef struct
ma_uint32 channels;
ma_uint32 sampleRate;
double cutoffFrequency;
} ma_hpf_config;
} ma_hpf2_config;
ma_hpf_config ma_hpf_config_init(ma_format format, ma_uint32 channels, ma_uint32 sampleRate, double cutoffFrequency);
ma_hpf2_config ma_hpf2_config_init(ma_format format, ma_uint32 channels, ma_uint32 sampleRate, double cutoffFrequency);
typedef struct
{
ma_biquad bq; /* The high-pass filter is implemented as a biquad filter. */
} ma_hpf;
ma_biquad bq; /* The 2-pole high-pass filter is implemented as a biquad filter. */