| 259 | } |
| 260 | |
| 261 | static int rtAudioCallback(void* outputBuffer, void* inputBuffer, unsigned int nFrames, double streamTime, RtAudioStreamStatus status, void* userData) { |
| 262 | // fprintf(stderr, "."); |
| 263 | // fflush(stderr); |
| 264 | |
| 265 | RtAudioDevice* that = (RtAudioDevice*) userData; |
| 266 | assert(that); |
| 267 | |
| 268 | system::setThreadName("RtAudio"); |
| 269 | |
| 270 | int inputStride = that->getNumInputs(); |
| 271 | int outputStride = that->getNumOutputs(); |
| 272 | try { |
| 273 | that->processBuffer((const float*) inputBuffer, inputStride, (float*) outputBuffer, outputStride, nFrames); |
| 274 | } |
| 275 | catch (Exception& e) { |
| 276 | // Log nothing to avoid spamming the log. |
| 277 | } |
| 278 | return 0; |
| 279 | } |
| 280 | }; |
| 281 | |
| 282 |
nothing calls this directly
no test coverage detected