mirror of
https://github.com/eried/portapack-mayhem.git
synced 2025-07-30 18:19:08 -04:00
Add IIR execute_in_place()
This commit is contained in:
parent
71990b380a
commit
876a591a66
2 changed files with 11 additions and 6 deletions
|
@ -39,12 +39,17 @@ public:
|
|||
{
|
||||
}
|
||||
|
||||
void execute(buffer_s16_t buffer) {
|
||||
for(size_t i=0; i<buffer.count; i++) {
|
||||
buffer.p[i] = execute_sample(buffer.p[i]);
|
||||
void execute(buffer_s16_t buffer_in, buffer_s16_t buffer_out) {
|
||||
// TODO: Assert that buffer_out.count == buffer_in.count.
|
||||
for(size_t i=0; i<buffer_out.count; i++) {
|
||||
buffer_out.p[i] = execute_sample(buffer_in.p[i]);
|
||||
}
|
||||
}
|
||||
|
||||
void execute_in_place(buffer_s16_t buffer) {
|
||||
execute(buffer, buffer);
|
||||
}
|
||||
|
||||
private:
|
||||
const std::array<float, 3> b;
|
||||
const std::array<float, 3> a;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue