Difference between revisions of "FTXP (File Format)"
Jump to navigation
Jump to search
(Just a stub. I will try to find out more later) |
m |
||
Line 1: | Line 1: | ||
{{under-construction}} | {{under-construction}} | ||
− | '''FTXP''' files (ca'''F'''e '''T'''e'''X'''ture '''P'''attern) are texture pattern animation files found into [[BFRES]] files. It contains animation data about which texture that should be rendered at what time. Unless otherwise noted, all offsets in the file are relative to themselves. | + | '''FTXP''' files (ca'''F'''e '''T'''e'''X'''ture '''P'''attern) are texture pattern animation files found into [[BFRES]] files in the '''6:th''' group. It contains animation data about which texture that should be rendered at what time. Unless otherwise noted, all offsets in the file are relative to themselves. |
== Header == | == Header == | ||
Line 11: | Line 11: | ||
| 0x00 || String || '''File magic'''. Always ''FTXP'' in ASCII. | | 0x00 || String || '''File magic'''. Always ''FTXP'' in ASCII. | ||
|- | |- | ||
− | | 0x04 || Int32 || ''' | + | | 0x04 || Int32 || '''Filename''' offset. The name of this file. |
|- | |- | ||
− | | 0x08 || Int32 || '''String table''' | + | | 0x08 || Int32 || End of '''[[BFRES#String Table|String table]]''' offset. |
|- | |- | ||
| 0x0C || UInt16 || Flags. | | 0x0C || UInt16 || Flags. | ||
Line 55: | Line 55: | ||
| 0x08 || UInt32 || '''Unknown'''. | | 0x08 || UInt32 || '''Unknown'''. | ||
|- | |- | ||
− | | 0x0C || UInt32 || '''Name offset'''. Points to the name of this material into the string table. | + | | 0x0C || UInt32 || '''Name offset'''. Points to the name of this material into the [[BFRES#String Table|string table]]. |
|- | |- | ||
| 0x10 || Sampler reference['''N'''] || Sampler references. The offsets are relative to 0x10 in this structure. | | 0x10 || Sampler reference['''N'''] || Sampler references. The offsets are relative to 0x10 in this structure. | ||
Line 80: | Line 80: | ||
| 0x02 || UInt16 || '''Unknown'''. | | 0x02 || UInt16 || '''Unknown'''. | ||
|- | |- | ||
− | | 0x04 || Int32 || '''Sampler name''' offset into the string table. | + | | 0x04 || Int32 || '''Sampler name''' offset into the [[BFRES#String Table|string table]]. |
|} | |} | ||
Line 119: | Line 119: | ||
! Offset !! Type !! Description | ! Offset !! Type !! Description | ||
|- | |- | ||
− | | 0x00 || Int32['''N'''] || '''N''' offsets to the strings. The strings are null-termined and comes directly after this array. They're not stored in the string table. | + | | 0x00 || Int32['''N'''] || '''N''' offsets to the strings. The strings are null-termined and comes directly after this array. They're not stored in the [[BFRES#String Table|string table]]. |
|} | |} | ||
[[Category:File Format]] | [[Category:File Format]] |
Revision as of 09:40, 1 April 2017
Under Construction
This article is not finished. Help improve it by adding accurate information or correcting grammar and spelling.
FTXP files (caFe TeXture Pattern) are texture pattern animation files found into BFRES files in the 6:th group. It contains animation data about which texture that should be rendered at what time. Unless otherwise noted, all offsets in the file are relative to themselves.
Header
The file starts with a 0x38 bytes long header.
Offset | Type | Description |
---|---|---|
0x00 | String | File magic. Always FTXP in ASCII. |
0x04 | Int32 | Filename offset. The name of this file. |
0x08 | Int32 | End of String table offset. |
0x0C | UInt16 | Flags. |
0x0E | UInt16 | Number of user data. |
0x10 | UInt32 | Number of frames. |
0x14 | UInt16 | Number of textures. |
0x16 | UInt16 | Number of material targets. |
0x18 | UInt32 | Unknown. |
0x1C | UInt32 | Unknown. |
0x20 | UInt32 | Unknown. |
0x24 | UInt32 | Unknown. |
0x28 | UInt32 | Unknown. |
0x2C | Int32 | Material array offset. |
0x30 | Int32 | Texture index group offset. The groups points to FTEX filenames and FTEX headers. |
0x34 | Int32 | User data index group offset. |
Material
Offset | Type | Description |
---|---|---|
0x00 | UInt16 | N = Number of samplers. |
0x02 | UInt16 | Unknown. |
0x04 | UInt32 | Unknown. |
0x08 | UInt32 | Unknown. |
0x0C | UInt32 | Name offset. Points to the name of this material into the string table. |
0x10 | Sampler reference[N] | Sampler references. The offsets are relative to 0x10 in this structure. |
Sampler reference
Offset | Type | Description |
---|---|---|
0x00 | UInt32 | Sampler offset. Relative to the end of the material structure. |
0x04 | UInt32 | Unknown. Probably an offset to something else. |
Sampler
Offset | Type | Description |
---|---|---|
0x00 | UInt16 | Unknown. |
0x02 | UInt16 | Unknown. |
0x04 | Int32 | Sampler name offset into the string table. |
User Data
The user data is stored into different entries, one for each type. The index group points to these entries.
Offset | Type | Description | |||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0x00 | Int32 | Name offset. Points to the string which is the name of this user data. | |||||||||||||||
0x04 | UInt16 | N = number of entries. | |||||||||||||||
0x06 | Byte | Type.
| |||||||||||||||
0x07 | Byte | Unknown. Always 0. |
Number
For user data with numbers the data comes directly after the user data header.
String
Offset | Type | Description |
---|---|---|
0x00 | Int32[N] | N offsets to the strings. The strings are null-termined and comes directly after this array. They're not stored in the string table. |