From 611983cc38e06bd99e9396b33a59704f34a9289d Mon Sep 17 00:00:00 2001 From: Vadim Zubkov Date: Sun, 28 Jan 2024 17:16:51 +0300 Subject: [PATCH] fix: set record callback interval to 20ms --- src/CSoundInput.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/CSoundInput.cpp b/src/CSoundInput.cpp index 3bde30b..fbbe013 100644 --- a/src/CSoundInput.cpp +++ b/src/CSoundInput.cpp @@ -149,7 +149,7 @@ AltVoiceError CSoundInput::SelectDeviceByUID(const char* uid) recording = true; - recordChannel = BASS_RecordStart(SAMPLE_RATE, AUDIO_CHANNELS, 0, OnSoundFrame, this); + recordChannel = BASS_RecordStart(SAMPLE_RATE, AUDIO_CHANNELS, MAKELONG(0, 20), OnSoundFrame, this); BASS_ChannelSetAttribute(recordChannel, BASS_ATTRIB_GRANULE, FRAME_SIZE_SAMPLES); // Change input volume