I am using the recorder.js library to output a WAV file in Chrome, but it's currently a 32-bit WAV file. I'm looking at this code here, but am not sure what to change to output a 16-bit WAV file. The audio file is mono (single-channel). I've read that I need to scale the values by 32,767 and then cast to 16-bit integer?
Unlike this question, I am not trying to downsample, or change the number of audio channels. I want to change the bit depth.