diff options
author | Poommetee Ketson <poommetee@protonmail.com> | 2017-07-08 22:12:18 +0700 |
---|---|---|
committer | Poommetee Ketson <poommetee@protonmail.com> | 2017-07-08 22:24:56 +0700 |
commit | 2fd204c35e6883d36d4c15adbe6725ffffd73c6f (patch) | |
tree | 2d1c630fe0f08014cfe8cca04fab9b1082c31aeb /servers/audio_server.cpp | |
parent | 0067982f5ece3145c00e2f4c0bc092d1ec28c8b3 (diff) | |
download | redot-engine-2fd204c35e6883d36d4c15adbe6725ffffd73c6f.tar.gz |
Refactor 'treshold' to 'threshold'
Diffstat (limited to 'servers/audio_server.cpp')
-rw-r--r-- | servers/audio_server.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/servers/audio_server.cpp b/servers/audio_server.cpp index 095e66ed37..f32784343c 100644 --- a/servers/audio_server.cpp +++ b/servers/audio_server.cpp @@ -252,7 +252,7 @@ void AudioServer::_mix_step() { if (!bus->channels[k].used) { //see if any audio is contained, because channel was not used - if (MAX(peak.r, peak.l) > Math::db2linear(channel_disable_treshold_db)) { + if (MAX(peak.r, peak.l) > Math::db2linear(channel_disable_threshold_db)) { bus->channels[k].last_mix_with_audio = mix_frames; } else if (mix_frames - bus->channels[k].last_mix_with_audio > channel_disable_frames) { bus->channels[k].active = false; @@ -713,7 +713,7 @@ bool AudioServer::is_bus_channel_active(int p_bus, int p_channel) const { void AudioServer::init() { - channel_disable_treshold_db = GLOBAL_DEF("audio/channel_disable_treshold_db", -60.0); + channel_disable_threshold_db = GLOBAL_DEF("audio/channel_disable_threshold_db", -60.0); channel_disable_frames = float(GLOBAL_DEF("audio/channel_disable_time", 2.0)) * get_mix_rate(); buffer_size = 1024; //harcoded for now switch (get_speaker_mode()) { |