MCPcopy Create free account
hub / github.com/LabSound/LabSound / setBufferSize

Method setBufferSize

src/backends/RtAudio/RtAudio.cpp:4223–4232  ·  view source on GitHub ↗

sets the length of the internal ring buffer

Source from the content-addressed store, hash-verified

4221
4222 // sets the length of the internal ring buffer
4223 void setBufferSize(unsigned int bufferSize, unsigned int formatBytes)
4224 {
4225 free(buffer_);
4226
4227 buffer_ = (char *) calloc(bufferSize, formatBytes);
4228
4229 bufferSize_ = bufferSize;
4230 inIndex_ = 0;
4231 outIndex_ = 0;
4232 }
4233
4234 // attempt to push a buffer into the ring buffer at the current "in" index
4235 bool pushBuffer(char * buffer, unsigned int bufferSize, RtAudioFormat format)

Callers 1

wasapiThreadMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected