mirror of
https://github.com/Shpoike/Quakespasm.git
synced 2025-03-21 10:11:10 +00:00
Clamp volume of 16-bit channels at 255 as well
This commit is contained in:
parent
85d97fac9a
commit
4dab33292e
1 changed files with 6 additions and 1 deletions
|
@ -289,7 +289,12 @@ void SND_PaintChannelFrom16 (channel_t *ch, sfxcache_t *sc, int count)
|
|||
int leftvol, rightvol;
|
||||
signed short *sfx;
|
||||
int i;
|
||||
|
||||
|
||||
if (ch->leftvol > 255)
|
||||
ch->leftvol = 255;
|
||||
if (ch->rightvol > 255)
|
||||
ch->rightvol = 255;
|
||||
|
||||
leftvol = ch->leftvol * snd_vol;
|
||||
rightvol = ch->rightvol * snd_vol;
|
||||
sfx = (signed short *)sc->data + ch->pos;
|
||||
|
|
Loading…
Reference in a new issue