[Olympus developers 305]: Re: raw file vs wav file, is there a good reason?
Gabriel Parent
gparent+ at cs.cmu.edu
Mon Jun 27 17:50:01 EDT 2011
If yinz look at the svn log, you'll see I just committed some changes to
the main trunk of Olympus. Here is the svn comments:
.wav files are now written instead of .raw files. 3 helper functions
have been added to libOlympusUtility (e.g., Writing header, closing
header), and AudioRecorder/AudioRecorderVoIP as well as AudioServer and
Kalliope have been modified to use those helper functions when creating
files.
The function WriteWavHeader defaults to use a sample rate of 8000, but
other sampling rate can be passed to it. Right now, the byte size
(e.g., 2 for 16 bits sample) is hardcoded. An extra argument could be
added if needed.
Gabriel
Alex Rudnicky wrote:
> The reasons were not very good ones:
>
> 1) at the time everything we were doing in interactive systems was 8kHz,
> so this was "understood" to be the format. (Or, you just "knew" what
> your data were.)
>
> 2) there was no really universally-accepted file format in ASR (except
> maybe for .sph).
>
> 3) to do it correctly, at the end of the recording you needed to fseek
> to the top of the file and put in the right numbers in the header (ie
> length). This was thought to impact speed (maybe a dubious proposition).
>
> 4) various other resource-constraint related reasons, none of which I
> believe are still operative.
>
> The right thing to do at this time would be to write a standard RIFF
> header (.wav). This would make the files readers by pretty much all
> tools out there; also, the format is flexible enough so that specialized
> information can easily be included in a data block without breaking
> anything.
>
> Alex
>
>
>
> -----Original Message-----
> From: olympus-developers-bounces at mailman.srv.cs.cmu.edu
> [mailto:olympus-developers-bounces at mailman.srv.cs.cmu.edu] On Behalf Of
> Gabriel Parent
> Sent: Friday, June 17, 2011 5:02 PM
> To: olympus-developers at mailman.srv.cs.cmu.edu
> Subject: [Olympus developers 302]: raw file vs wav file,is there a good
> reason?
>
> All,
>
> what was the initial reason for writing the utterance and system audio
> file as raw file versus wav file. Is the main reason to save disk space?
>
> Gabriel
>
More information about the Olympus-developers
mailing list