Original Python code and discussion at http://forum.pianoworld.com/ubbthreads.php/topics/3092415/re-realtime-pitch-based-velocity-filter-transformed-the-nu1x.html#Post3092415
Converted to JavaScript and enhanced by Kerri Shotts based on ideas in the above thread.
Parameters
- Transform: additive | multiplicative (default)