Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

How is a .WAV header ?

4 views
Skip to first unread message

Thunder

unread,
Sep 7, 1997, 3:00:00 AM9/7/97
to

I want to know where (in bytes) are located the file information &
specifications ...
I'd like to be able to read:
- The number of sampling bits (8 bits or 16 bits ? )
- The channels (stereo or mono)
- The sample rate
- The total length of the samples
- And all that would be available in the WAVE header

Thanks for ur help.

Bye!
Thunder

--
´¯`·.¸¸.·´¯`·.¸¸.·´¯`·.¸¸.·´¯`·.¸¸.´¯`

Thunder (Bruno)
e-mail: Bru...@mail.dotcom.fr

´¯`·.¸¸.·´¯`·.¸¸.·´¯`·.¸¸.·´¯`·.¸¸.´¯`


Qurt

unread,
Sep 9, 1997, 3:00:00 AM9/9/97
to Thunder

This is a multi-part message in MIME format.
--------------D44A3BD2B097C4063E388D35
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Here's a text file explaining the WAV format... this is an except from
the PCGPE
(PC game programmer's encyclopedia), which is available for download off
the web.

Hope it help...
-Qurt

Thunder wrote:

> I want to know where (in bytes) are located the file information &
> specifications ...
> I'd like to be able to read:
> - The number of sampling bits (8 bits or 16 bits ? )
> - The channels (stereo or mono)
> - The sample rate
> - The total length of the samples
> - And all that would be available in the WAVE header

--------------D44A3BD2B097C4063E388D35
Content-Type: text/plain; charset=iso-8859-1; name="Wav.txt"
Content-Transfer-Encoding: 8bit
Content-Disposition: inline; filename="Wav.txt"


ЪДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДї
і The Microsoft Multimedia WAV Sound File Format і
АДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДЩ

Written for the PC-GPE by Mark Feldman
e-mail address : u91...@student.canberra.edu.au
myn...@cairo.anu.edu.au

ЪДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДї
і THIS FILE MAY NOT BE DISTRIBUTED і
і SEPARATE TO THE ENTIRE PC-GPE COLLECTION. і
АДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДЩ


ЪДДДДДДДДДДДДВДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДД
і Disclaimer і
АДДДДДДДДДДДДЩ

I assume no responsibility whatsoever for any effect that this file, the
information contained therein or the use thereof has on you, your sanity,
computer, spouse, children, pets or anything else related to you or your
existance. No warranty is provided nor implied with this information.

ЪДДДДДДДДДДДДДДДДДДДДДДВДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДД
і The RIFF File Format і
АДДДДДДДДДДДДДДДДДДДДДДЩ

WAV files use the RIFF file structure. The RIFF format was designed
for multi-media purposes. A RIFF files consists of a number of "chunks":

ЪДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДї
і Byte Length і
і Offset Name (in bytes) Description і
ГДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДґ
і 00h rID 4h Contains the characters "RIFF" і
і 04h rLen 4h The length of the data in the next chunk і
і 08h rData rLen The data chunk і
АДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДЩ


ЪДДДДДДДДДДДДДДДДДДДДДДДДДДВДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДД
і The WAVE Form Definition і
АДДДДДДДДДДДДДДДДДДДДДДДДДДЩ

The rData chunk in a WAV file is split up into several further chunks:

ЪДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДї
і rData і
і Byte Length і
і Offset Name (in bytes) Description і
ГДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДґ
і 00h wID 4h Contains the characters "WAVE" і
і 04h Format 14h Contains data which specifies the format і
і Chunk of the Data in the Data Chunk і
і 18h WAVE Data ? Contains the WAV audio data і
і Chunk і
АДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДЩ

ЪДДДДДДДДДДДДДДДДДДВДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДД
і The Format Chunk і
АДДДДДДДДДДДДДДДДДДЩ

The Format Chunk is split up into these fields:

ЪДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДї
і Format і
і Chunk Length і
і Offset Name (in bytes) Description і
ГДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДґ
і 00h fId 4 Contains the characters "fmt" і
і 04h fLen 4 Length of data in the format chunk і
і 08h wFormatTag 2 * і
і 0Ah nChannels 2 Number of channels, 1=mono, 2=stereo і
і 0Ch nSamplesPerSec 2 Playback frequency і
і 0Eh nAvgBytesPerSec 2 ** і
і 10h nBlockAlign 2 *** і
і 12h FormatSpecific 2 Format specific data area і
АДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДЩ

* The wFormatTag specifies the wave format, eg 1 = Pulse Code Modulation
(or in plain english, regular 8 bit sampled uncompressed sound)

** Indicates the average number of bytes a second the data should be
transferred at = nChannels * nSamplesPerSec * (nBitsPerSample / 8)

*** Indicates the block alignment of the data in the data chunk. Software
needs to process a multiplt of nBlockAlign at a time.
nBlockAlign = nChannels * (nBitsPerSample / 8)


ЪДДДДДДДДДДДДДДДДВДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДД
і The Data Chunk і
АДДДДДДДДДДДДДДДДЩ

The Data Chunk is split up into these fields:

ЪДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДї
і Data і
і Chunk Length і
і Offset Name (in bytes) Description і
ГДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДґ
і 00h dId 4 Contains the characters "data" і
і 02h dLen 4 Length of data in the dData field і
і 00h dData dLen The actual waveform data і
АДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДДЩ

In mono 8-bit files each byte represents one sample. In stereo 8-bit files
two bytes are stored for each sample, the first byte is the left channel
value, the next is the right channel value.

--------------D44A3BD2B097C4063E388D35--


Alex Warren

unread,
Sep 10, 1997, 3:00:00 AM9/10/97
to

On 8 Sep 1997 18:29:11 GMT, "DELEAU Jean-Marie" <-d...@euronet.be>
wrote:

>
>Va au site suivant :
>
>http://www.wotsit.demon.co.uk/music.htm
>Il y a une description de plusieurs formats de fichier sonore (en autre le
>format WAV)
>
>JM

I don't know if the original question was in French or English,
therefore I shall *TRY* to provide a translation.


ENGLISH: Download the PC Games Programmers Encyclopedia from
ftp://x2ftp.oulu.fi/pub/msdos/programming/gpe

It has lots of information on the WAV format plus lots more formats
such as VOC, etc.

Also, you might want to try the Basix Fanzine. Issue 7 contains a very
good WAV file player for QuickBasic. Download it from
http://www.trenham.demon.co.uk/ and click on Back Issues.


(Now for a BAD translation, a bit pointless as the documentation
mentioned above is in English! Oh well, never mind...)


FRANCAIS: Telechargez le PC-GPE de
ftp://x2ftp.oulu.fi/pub/msdos/programming/gpe. (C'est en anglais,
alors je ne sais pas porquoi j'ai fait ce traduction!)

Aussi, il y a le "Basix Fanzine", qu'on peut telecharger a
http://www.trenham.demon.co.uk/ (choissisez "Back Issues"). C'est
aussi en anglais... Numero 7 est tres bien, il y a un "WAV-player".
(Je ne crois pas que c'est un mot francais, mais...)


Un mal traduction, et inutile aussi?

Alex Warren
email: dew...@globalnet.co.uk
www: http://www.users.globalnet.co.uk/~dewarr/

Hugo Jonker

unread,
Sep 10, 1997, 3:00:00 AM9/10/97
to

Alex Warren (dew...@globalnet.co.uk) thought about:

> On 8 Sep 1997 18:29:11 GMT, "DELEAU Jean-Marie" <-d...@euronet.be>
> wrote:
> >Va au site suivant :
> >http://www.wotsit.demon.co.uk/music.htm
> >Il y a une description de plusieurs formats de fichier sonore (en autre le
> >format WAV)
> I don't know if the original question was in French or English,
> therefore I shall *TRY* to provide a translation.

Okay, do your best.

> ENGLISH: Download the PC Games Programmers Encyclopedia from
> ftp://x2ftp.oulu.fi/pub/msdos/programming/gpe

X-cuse me ????? I do not see the PCGPE mentioned anywhere in the French
text. Nor do I see any other internet address then:

> >http://www.wotsit.demon.co.uk/music.htm

which doesn't even resemble an ftp address....

> It has lots of information on the WAV format plus lots more formats
> such as VOC, etc.

So you're not translating anything I guess ?
I have to agree that PCGPE is quite good...

> Also, you might want to try the Basix Fanzine. Issue 7 contains a very
> good WAV file player for QuickBasic. Download it from
> http://www.trenham.demon.co.uk/ and click on Back Issues.

> (Now for a BAD translation, a bit pointless as the documentation
> mentioned above is in English! Oh well, never mind...)


> FRANCAIS: Telechargez le PC-GPE de
> ftp://x2ftp.oulu.fi/pub/msdos/programming/gpe. (C'est en anglais,
> alors je ne sais pas porquoi j'ai fait ce traduction!)

Je ne sais pas aussi, es tu fou ??? Non, je ne croix pas...

> Aussi, il y a le "Basix Fanzine", qu'on peut telecharger a
> http://www.trenham.demon.co.uk/ (choissisez "Back Issues"). C'est
> aussi en anglais... Numero 7 est tres bien, il y a un "WAV-player".
> (Je ne crois pas que c'est un mot francais, mais...)

jouer de .WAV-files ??? Il y a du chance que ca est un mot francais...
Ma francais est terrible, parce que je ne viennent pas aux lectoires a une
annee. Oui, c'est terrible.... je sais...

> Un mal traduction, et inutile aussi?

Un vrais programmeur des ordinateurs parlez anglais, je croix...

And now for a translation of the original french text:

> >Va au site suivant :

Go swiftly to this site:

> >http://www.wotsit.demon.co.uk/music.htm

Speaks for itself...

> >Il y a une description de plusieurs formats de fichier sonore (en autre le
> >format WAV)

They have a desciption of multiple sound formats (among which the .WAV
format)

--
Bel...@stack.nl
.oO Those who know cannot explain, those who don't cannot understand Oo.

0 new messages