Anonymous

Changes

From Final Fantasy Inside

FF7/Kernel/Low level libraries

5,824 bytes added, 05:26, 10 March 2005
no edit summary
== PC to PSX comparison ==

The files and data formats used in the PSX version of FF7 and it's PC port are conceptually the same thing, and accomplish the same tasks. That being said, they both have wildly different formats. Both ofwhich were derived from a third original format that is also somewhat different that the first two.

The original PSX FF7 was created in part using Sony's Psy-Q development library. This library usescommon formats that are "native" to the PSX. Often times a toolkit was used to convert commondevelopment- based formats, such as a TGA bitmap or a palleted GIF file, to something a little moresuited to Psy-Q, which would be a TIM file.

During the porting process to the PC, some of the original artwork, (and artists for that matter), wereno longer available. This resulted in the port team having to use the Psy-Q versions of many files,which were ill suited for the PC architecture. In our example, the TIM file was converted to a TEX file,which would be manipulated in the PC's video memory a little more efficiently. Sometimes theoriginal artwork was available, such as the pictures of the characters within the menu, or the originalMIDI files. Most often times it was not.

To make things a little more confusing, both systems also archive their data files in different ways,making the extraction and rendering of each file a bit of a bear. For the most part the data within eachfile is the same thing, just a little switched around. This manual will cover the more generic files first,and then common files used in each module.

== DATA ARCHIVES ==

To save space, quicken access time, and to obfuscate the file structure a little, most of the data files are stored in some kind of archive format. The archives remove such useful items as subdirectories and logical data placement. There is no real "native" format these are based on.

== BIN archive data format ==

The BIN format comes as two different types. They both have the same extension, so one must open the file to see which format is which. They are best described as BIN Types and Bin-GZIP types

BIN Types

These are uncompressed archives. The header consists of a 4 byte header that gives the length of the file without the header and then the data beyond that.

BIN-GZIP Types

Unless otherwise noted, these have a 6 byte header. After this are many gziped sections concatenated together.


<table CELLSPACING="0"; style="margin-bottom: 0px;">
<tr>
<th style="border: 1px solid rgb(0, 0, 0); vertical-align: middle; width: 58px; height: 25px; background-color: rgb(230, 230, 230);">
Offset</th>
<th style="border: 1px solid rgb(0, 0, 0); vertical-align: middle; width: 58px; height: 25px; background-color: rgb(230, 230, 230);">
Length</th>
<th style="border: 1px solid rgb(0, 0, 0); vertical-align: middle; width: 310px; height: 25px; background-color: rgb(230, 230, 230);">
Description</th>
</tr>

<tr>
<td style="border: 1px solid rgb(0, 0, 0); width: 58px; height: 25px;">
0x0000</td>
<td style="border: 1px solid rgb(0, 0, 0); width: 58px; height: 25px;">
2 bytes</td>
<td style="border: 1px solid rgb(0, 0, 0); width: 310px; height: 25px;">
Length of gzipped sections</td>
</tr>

<tr>
<td style="border: 1px solid rgb(0, 0, 0); width: 58px; height: 25px; background-color: rgb(255, 255, 204);">
0x0002</td>
<td style="border: 1px solid rgb(0, 0, 0); width: 58px; height: 25px; background-color: rgb(255, 255, 204);">
2 bytes</td>
<td style="border: 1px solid rgb(0, 0, 0); width: 310px; height: 25px; background-color: rgb(255, 255, 204);">
Unknown</td>
</tr>

<tr>
<td style="border: 1px solid rgb(0, 0, 0); width: 58px; height: 25px;">
0x0004</td>
<td style="border: 1px solid rgb(0, 0, 0); width: 58px; height: 25px;">
2 bytes</td>
<td style="border: 1px solid rgb(0, 0, 0); width: 310px; height: 25px;">
File number</td>
</tr>

<tr>
<td style="border: 1px solid rgb(0, 0, 0); width: 58px; height: 25px;">
0x0006</td>
<td style="border: 1px solid rgb(0, 0, 0); width: 58px; height: 25px;">
varies</td>
<td style="border: 1px solid rgb(0, 0, 0); width: 310px; height: 25px;">
[0x1F8B080000000000.....] - Gzip header 1</td>
</tr>

<tr>
<td style="border: 1px solid rgb(0, 0, 0); width: 58px; height: 25px;">
varies</td>
<td style="border: 1px solid rgb(0, 0, 0); width: 58px; height: 25px;">
2 bytes</td>
<td style="border: 1px solid rgb(0, 0, 0); width: 310px; height: 25px;">
Length of gzipped sections</td>
</tr>

<tr>
<td style="border: 1px solid rgb(0, 0, 0); width: 58px; height: 25px; background-color: rgb(255, 255, 204);">
varies</td>
<td style="border: 1px solid rgb(0, 0, 0); width: 58px; height: 25px; background-color: rgb(255, 255, 204);">
2 bytes</td>
<td style="border: 1px solid rgb(0, 0, 0); width: 310px; height: 25px; background-color: rgb(255, 255, 204);">
Unknown</td>
</tr>

<tr>
<td style="border: 1px solid rgb(0, 0, 0); width: 58px; height: 25px;">
varies</td>
<td style="border: 1px solid rgb(0, 0, 0); width: 58px; height: 25px;">
2 bytes</td>
<td style="border: 1px solid rgb(0, 0, 0); width: 310px; height: 25px;">
File number</td>
</tr>

<tr>
<td style="border: 1px solid rgb(0, 0, 0); width: 58px; height: 25px;">
varies</td>
<td style="border: 1px solid rgb(0, 0, 0); width: 58px; height: 25px;">
varies</td>
<td style="border: 1px solid rgb(0, 0, 0); width: 310px; height: 25px;">
[0x1F8B080000000000.....] - Gzip header 2</td>
</tr>

<tr>
<td style="border-style: solid none solid solid; border-color: rgb(0, 0, 0); border-width: 1px; vertical-align: top; width: 58px; height: 25px;">
</td><td style="border-style: solid none; border-color: rgb(0, 0, 0); border-width: 1px; vertical-align: top; width: 58px; height: 25px;">
</td><td style="border-style: solid solid solid none; border-color: rgb(0, 0, 0); border-width: 1px; width: 310px; height: 25px;">
...</td>
</tr>
</table>
Anonymous user