搜尋此網誌

2009年10月13日 星期二

暫存

最近在處理對聲音判斷其音量大小 目前有點卡關 暫存一些我查到的資訊
似乎是可以利用sample size 和number of channels 來決定此音源的音量大小

Digital audio is stored as a series of samples, where each sample is the amplitude of the sound wave being recorded. The volume of the sound is the same as the amplitude of the sound, therefore, each individual sample is simply encoded as the volume of the sound.

So you break the mic input down into a list of samples (based on the sample size / number of channels) and keep a running average to determine the sound level.

沒有留言:

張貼留言