I'm new to audio analysis, but I need to complete a (seemingly) simple task. I have a byte array containing 16-bit recording (one channel) and a sampling rate of 44100. How to perform a quick analysis to get the volume at any time? I need to calculate the threshold, so the function returns true if it is above a certain amplitude (volume) and false if not. I thought I could iterate over the byte array and check its value, with 255 being the loudest, but it doesn’t seem to work even when I am not recording anything, there is background noise, and part of the array is filled with 255. Any suggestions would be great. Thanks
source
share