AST (File Format)

From Custom Mario Kart
Revision as of 19:52, 10 July 2017 by Atlas (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

AST files are sound files used in some Wii games such as Super Mario Galaxy 1 & 2. The file contains a header followed by blocks with data.

File Format

Header

The file starts with a 0x40 bytes long header as follows:

Offset Type Description
0x00 String File magic. Always STRM in ASCII.
0x04 UInt32 Size of all sound blocks, thus file size - 0x40.
0x08 UInt16 Audio format. 0 = ADPCM, 1 = PCM16.
0x0A UInt16 Bit depth. Usually 16.
0x0C UInt16 Number of channels.
0x0E UInt16 Unknown.
0x10 UInt32 Sample rate.
0x14 UInt32 Total number of samples.
0x18 UInt32 Loop start in samples.
0x1C UInt32 Loop end in samples.
0x20 UInt32 Seems to be the block size of the first block.
0x24 UInt32 Unknown. Only seen as 0.
0x28 UInt32 Unknown. Only seen as 0x7F000000.
0x2C Byte[0x1C] Unknown. Only seen as 0. Probably padding.
0x40 End of file header

BLCK

A file contains many BLCK sections which contain sound data. Each block has the following structure:

Offset Type Description
0x00 String Block magic. Always BLCK in ASCII.
0x04 UInt32 B = Block size.
0x08 Byte[0x18] Unknown. Probably padding to align sound data.
0x20 Byte[B] Sound data.

Tools

The following tools can handle AST files: