Implement a limiter on the device output
commitca5c732261bfacdb4702fcc253b3ef0dad357a35
authorChris Robinson <chris.kcat@gmail.com>
Thu, 27 Apr 2017 01:38:09 +0000 (26 18:38 -0700)
committerChris Robinson <chris.kcat@gmail.com>
Thu, 27 Apr 2017 01:38:09 +0000 (26 18:38 -0700)
tree9d9ff19e5bc80a3a5d44ba2c7a464b85097d37f1
parent1754d54c18b58995718d2695151a945ee232b0f1
Implement a limiter on the device output

This reduces the output volume when the mixed samples extend outside of -1,+1,
to prevent excessive clipping. It can reduce the volume by -80dB in 50ms, and
increase it by +80dB in 1s (it will not go below -80dB or above 0dB).
Alc/ALc.c
Alc/ALu.c
OpenAL32/Include/alMain.h