RtAudio: Restore previous (incorrect but safer) buffer size

See #10683 for a potential better fix, but this close to the 2.1.4 release
I am taking the safe route.
This commit is contained in:
Rémi Verschelde 2017-08-27 10:12:25 +02:00
parent 40a778a709
commit cf80fbc95c

View file

@ -115,7 +115,7 @@ Error AudioDriverRtAudio::init() {
int latency = GLOBAL_DEF("audio/output_latency", 25); int latency = GLOBAL_DEF("audio/output_latency", 25);
// calculate desired buffer_size, taking the desired numberOfBuffers into account (latency depends on numberOfBuffers*buffer_size) // calculate desired buffer_size, taking the desired numberOfBuffers into account (latency depends on numberOfBuffers*buffer_size)
unsigned int buffer_size = closest_power_of_2(latency * mix_rate / 1000 / target_number_of_buffers); unsigned int buffer_size = next_power_of_2(latency * mix_rate / 1000 / target_number_of_buffers);
if (OS::get_singleton()->is_stdout_verbose()) { if (OS::get_singleton()->is_stdout_verbose()) {
print_line("audio buffer size: " + itos(buffer_size)); print_line("audio buffer size: " + itos(buffer_size));