mirror of
https://github.com/firestar5683/StarPilot.git
synced 2026-06-29 10:32:10 +08:00
soundd: increase upper bound for volume level (#26792)
Update sound.cc old-commit-hash: 0c1fbe22b4d83ee5873c992d02b9bc46fd16ae7b
This commit is contained in:
@@ -48,7 +48,7 @@ void Sound::update() {
|
||||
|
||||
// scale volume using ambient noise level
|
||||
if (sm.updated("microphone")) {
|
||||
float volume = util::map_val(sm["microphone"].getMicrophone().getFilteredSoundPressureWeightedDb(), 30.f, 54.f, 0.f, 1.f);
|
||||
float volume = util::map_val(sm["microphone"].getMicrophone().getFilteredSoundPressureWeightedDb(), 30.f, 56.f, 0.f, 1.f);
|
||||
volume = QAudio::convertVolume(volume, QAudio::LogarithmicVolumeScale, QAudio::LinearVolumeScale);
|
||||
Hardware::set_volume(volume);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user