Interleaf File

Revision as of 02:55, 14 January 2020 by MattKC (talk | contribs) (→‎Version)

An Interleaf File (extension .SI) is a general purpose asset archive format designed for streaming from CD-ROM. It was developed by Mindscape for use throughout LEGO Island.

Overview

The Interleaf file format is exclusive to LEGO Island, and therefore was never officially documented publicly. All information known about this format has been through reverse engineering or interviews with game developers.

Interleaf files are derived from the Resource Interchange File Format standard (best known as the basis of Audio Video Interleave and WAV files). They are comprised of various LEGO Island-specific structures (such as MxDa and MxCh), however these structures usually contain standard format file data (such as PCM WAV audio and Windows BMP images).

The primary purpose of Interleaf files is to split various file formats into smaller chunks that are interleaved together so they can all be read as one continuous stream. For example, a chunk of voice data may be followed by a chunk of matching animation data or a bitmapped graphic. This is done to reduce the amount of seeking around the disc for assets since CD-ROM speeds of the era were generally very slow and end-user hard drive space was usually too limited to store much game data.

Interleaf files were produced internally with a tool called Weaver, however this tool has never been publicly released or leaked.

Version

Interleaf files went through a number of revisions, as indicated by this error message that's thrown if an SI version doesn't match:

 

The SI version is set in an SI file's MxHD section. The version used in both retail versions is 2.2.

Modification

As aforementioned, no official documentation of Interleaf files has ever been released. There are a handful of tools for working with them (e.g. LEGO Island Rebuilder), but none with a complete implementation. Therefore, manual hex editing is often used to replace or extract assets.

When working with Interleaf files, this interleaving needs to be taken account as it will dictate how the data is both extracted and inserted. One file stream may be separated into several chunks with chunks of other files interleaved between them.

Since audio is stored in PCM, Interleaf files can be crudely listened to using Audacity's "Import Raw Data" feature. SI audio is always uncompressed mono PCM and is either 11025 Hz and 16-bit or 22050 Hz and 8-bit. Unfortunately due to the aforementioned chunked/interleaved nature of SI files, the audio retrieved through this method will be noticeably glitchy and will require further processing (removal of chunk headers and any non-audio chunks) to extract clean PCM data.

See also