MCPcopy Create free account
hub / github.com/cycfi/q / process

Method process

example/io_delay.cpp:32–52  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

30 {}
31
32 void process(in_channels const& in, out_channels const& out)
33 {
34 auto left = out[0];
35 auto right = out[1];
36 auto ch0 = in[0];
37 for (auto frame : out.frames)
38 {
39 // Get the next input sample
40 auto s = ch0[frame];
41
42 // Mix the signal and the delayed signal
43 _y = s + _delay();
44
45 // Feed back the result to the delay
46 _delay.push(_y * _feedback);
47
48 // Output
49 left[frame] = s;
50 right[frame] = _y;
51 }
52 }
53
54 q::delay _delay;
55 float _feedback;

Callers

nothing calls this directly

Calls 1

pushMethod · 0.80

Tested by

no test coverage detected