Enumeration RtAudioStreamFlags

The following flags can be OR'ed together to allow a client to make changes to the default stream behavior.

By default, RtAudio streams pass and receive audio data from the client in an interleaved format. By passing the RTAUDIO_NONINTERLEAVED flag to the openStream() function, audio data will instead be presented in non-interleaved buffers. In this case, each buffer argument in the RtAudioCallback function will point to a single array of data, with \c nFrames samples for each channel concatenated back-to-back. For example, the first sample of data for the second channel would be located at index \c nFrames (assuming the \c buffer pointer was recast to the correct data type for the stream).

Certain audio APIs offer a number of parameters that influence the I/O latency of a stream. By default, RtAudio will attempt to set these parameters internally for robust (glitch-free) performance (though some APIs, like Windows DirectSound, make this difficult). By passing the RTAUDIO_MINIMIZE_LATENCY flag to the openStream() function, internal stream settings will be influenced in an attempt to minimize stream latency, though possibly at the expense of stream performance.

If the RTAUDIO_HOG_DEVICE flag is set, RtAudio will attempt to open the input and/or output stream device(s) for exclusive use. Note that this is not possible with all supported audio APIs.

If the RTAUDIO_SCHEDULE_REALTIME flag is set, RtAudio will attempt to select realtime scheduling (round-robin) for the callback thread.

Enumeration Members

RTAUDIO_NONINTERLEAVED: 1

Use non-interleaved buffers (default = interleaved).

RTAUDIO_MINIMIZE_LATENCY: 2

Attempt to set stream parameters for lowest possible latency.

RTAUDIO_HOG_DEVICE: 4

Attempt grab device and prevent use by others.

RTAUDIO_SCHEDULE_REALTIME: 8

Try to select realtime scheduling for callback thread.

RTAUDIO_ALSA_USE_DEFAULT: 16

Use the "default" PCM device (ALSA only).

RTAUDIO_JACK_DONT_CONNECT: 32

Do not automatically connect ports (JACK only).

Generated using TypeDoc