#173777 - Ruben - Fri Apr 30, 2010 11:45 am
Hi.
So I was doing some work on my Midi music player [and yes, once I actually implement bank loads it'll be adjusted to work with libnds as well]... and decided that it's time to work with shifted volume [that is, using the hardware /2, /4, /16 values]. My first attempt was rather bad as it compared the limits of 3 possibilities. I know MaxMod uses a LUT, but is there a better way to calculate a volume + shift when one has a 25-bit accuracy, 7-bit integer value as volume?
So I was doing some work on my Midi music player [and yes, once I actually implement bank loads it'll be adjusted to work with libnds as well]... and decided that it's time to work with shifted volume [that is, using the hardware /2, /4, /16 values]. My first attempt was rather bad as it compared the limits of 3 possibilities. I know MaxMod uses a LUT, but is there a better way to calculate a volume + shift when one has a 25-bit accuracy, 7-bit integer value as volume?