| 44 | } |
| 45 | |
| 46 | void Inverter::Process(double time) |
| 47 | { |
| 48 | PROFILER(Inverter); |
| 49 | |
| 50 | SyncBuffers(); |
| 51 | |
| 52 | IAudioReceiver* target = GetTarget(); |
| 53 | |
| 54 | if (target) |
| 55 | { |
| 56 | ChannelBuffer* out = target->GetBuffer(); |
| 57 | for (int ch = 0; ch < GetBuffer()->NumActiveChannels(); ++ch) |
| 58 | { |
| 59 | if (mEnabled) |
| 60 | Mult(GetBuffer()->GetChannel(ch), -1, out->BufferSize()); |
| 61 | Add(out->GetChannel(ch), GetBuffer()->GetChannel(ch), out->BufferSize()); |
| 62 | GetVizBuffer()->WriteChunk(GetBuffer()->GetChannel(ch), GetBuffer()->BufferSize(), ch); |
| 63 | } |
| 64 | } |
| 65 | |
| 66 | GetBuffer()->Reset(); |
| 67 | } |
| 68 | |
| 69 | void Inverter::DrawModule() |
| 70 | { |
nothing calls this directly
no test coverage detected