Skip to content

Commit

Permalink
set rtaudio low latency options only on linux
Browse files Browse the repository at this point in the history
  • Loading branch information
sreimers committed Mar 31, 2019
1 parent be40064 commit 7169834
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/modules/slrtaudio/slrtaudio.c
Original file line number Diff line number Diff line change
Expand Up @@ -651,9 +651,16 @@ static int slrtaudio_start(void)
.flags = RTAUDIO_FLAGS_SCHEDULE_REALTIME + RTAUDIO_FLAGS_MINIMIZE_LATENCY,
};

#ifdef LINUX
rtaudio_open_stream(audio, &out_params, &in_params,
RTAUDIO_FORMAT_SINT16, 48000, &bufsz,
slrtaudio_callback, NULL, &options, NULL);
#else
rtaudio_open_stream(audio, &out_params, &in_params,
RTAUDIO_FORMAT_SINT16, 48000, &bufsz,
slrtaudio_callback, NULL, NULL, NULL);
#endif

if (rtaudio_error(audio) != NULL) {
err = EINVAL;
goto out;
Expand Down

0 comments on commit 7169834

Please sign in to comment.