OPL and OPLL vol map

This commit is contained in:
tildearrow 2023-12-17 14:54:38 -05:00
parent 8d30ac4d3b
commit 0208883fa1
6 changed files with 26 additions and 2 deletions

View file

@ -191,7 +191,7 @@ class DivPlatformOPN: public DivPlatformFMBase {
if (ch==adpcmBChanOffs) return vel*255.0;
if (ch>=adpcmAChanOffs) {
if (vel==0) return 0;
if (vel==127) return 31;
if (vel>=1.0) return 31;
return CLAMP(round(32.0-(56.0-log2(vel*127.0)*8.0)),0,31);
}
if (ch>=psgChanOffs) return round(15.0*pow(vel,0.33));