| 262 | } |
| 263 | |
| 264 | void ADSRNode::process(ContextRenderLock& r, int bufferSize) |
| 265 | { |
| 266 | AudioBus* destinationBus = output(0)->bus(r); |
| 267 | AudioBus* sourceBus = input(0)->bus(r); |
| 268 | if (!isInitialized() || !input(0)->isConnected()) |
| 269 | { |
| 270 | destinationBus->zero(); |
| 271 | return; |
| 272 | } |
| 273 | |
| 274 | int numberOfInputChannels = input(0)->numberOfChannels(r); |
| 275 | if (numberOfInputChannels != output(0)->numberOfChannels()) |
| 276 | { |
| 277 | output(0)->setNumberOfChannels(r, numberOfInputChannels); |
| 278 | destinationBus = output(0)->bus(r); |
| 279 | } |
| 280 | |
| 281 | // process entire buffer |
| 282 | adsr_impl->process(r, sourceBus, destinationBus, bufferSize); |
| 283 | } |
| 284 | |
| 285 | void ADSRNode::reset(ContextRenderLock&) |
| 286 | { |
nothing calls this directly
no test coverage detected