I know its more a basic audio question but I think its a very easy one for people in this group.
I'm working a lot with raw bytes for pre-proccesing and filtering before sending audio to PS.
I want to know exactly what the raw audio bytes represent 16-bit signed PCM mono, but only can find topics about stereo.
So here is the part I just want to be sure;
This is the format for stereo (found on some forum thread)
byte | 01 02 | 03 04 | 05 06 | 07 08 | 09 10 | 11 12 | ...
channel | Left | Right | Left | Right | Left | Right | ...
frame | First | Second | Third | ...
sample | 1st L | 1st R | 2nd L | 2nd R | 3rd L | 3rd R | ... etc.
You need to provide the example, but generally there should be no such thing. Values in PCM files could be arbitrary. The scale of the sample values are from -32767 to 32767.
Last edit: Nickolay V. Shmyrev 2016-04-05
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Any idea why even bytes are positive and uneven are negative?
In your audio not every even byte is positive and not every odd byte is negative. You see the white noise which is expected in the beginning of the audio.
I know its more a basic audio question but I think its a very easy one for people in this group.
I'm working a lot with raw bytes for pre-proccesing and filtering before sending audio to PS.
I want to know exactly what the raw audio bytes represent 16-bit signed PCM mono, but only can find topics about stereo.
So here is the part I just want to be sure;
This is the format for stereo (found on some forum thread)
How does this differ from the MONO format?
PS: when investigating the raw bytes I notice the even bytes are positive and uneven are negative, is the represeted in the sinus as upper and lower amplitude like on: http://manual.audacityteam.org/o/m/images/1/1f/trackexampledb.png ?
Hope someone can clear this up
In mono format you have just one channel, so one frame contains one sample instead of two
You need to provide the example, but generally there should be no such thing. Values in PCM files could be arbitrary. The scale of the sample values are from -32767 to 32767.
Last edit: Nickolay V. Shmyrev 2016-04-05
Nickolay, thanks again for the info.
Good to get this 100% sure, it was a litle obvious but nowhere clearly noted.
I checked the 'goforward.raw' example and that indeed seems to not have a sinus like behaviour.
But I'm still wondering what could be the cause of this in https://onedrive.live.com/redir?resid=53DF68CA92747BA6%21231790
Any idea why even bytes are positive and uneven are negative?
In your audio not every even byte is positive and not every odd byte is negative. You see the white noise which is expected in the beginning of the audio.
White noise is caused by Brownian motion of atoms in our universe. If you amplify it many times you can listen for it.
OK, thanks for the interesting info.
So,i think its not a bad idea to make/implement a noise filter ;-)
Pocketsphinx already has noise filter, you do not need to impelment anything special.
Thanks for the notification.