Changes

Jump to navigation Jump to search

FF8/FileFormat X

5,815 bytes added, 19:05, 24 February 2015
Created page with "By MaKiPL. Thanks for help in research for: shakotay2 (XeNTaX), Halfer, Yagami Light. == Info == .X file is uncompressed 3D stage model with texture embedeed. The file con..."
By MaKiPL. Thanks for help in research for: shakotay2 (XeNTaX), Halfer, Yagami Light.

== Info ==

.X file is uncompressed 3D stage model with texture embedeed. The file contains basic info (currently unknown, probably for editor?), camera data, movement, translations and geometry data.

{| border="1" cellspacing="1" cellpadding="3" align="center" style="border: 1px solid black; border-collapse: collapse;"
! style="background:rgb(204,204,204)" | Name
! style="background:rgb(204,204,204)" | Usually starting with:
! style="background:rgb(204,204,204)" | Description
|-
| Info/Script
| E8 FF BD 27 01 00 02
| Currently unknown. Probably header + info, that is not needed in game itself. Can be null'ied and nothing will happen ingame.
|-
| Camera data + movement
| 02 00 08 00 20 00 (usually 0x5d4/8)
| Camera animations, movement (pre-keyed)
|-
| Geometry
| 01 00 00 00 08 (See geometry section info)
| Divides to object and it's sub-objects
|-
| Texture
| 01 00 00 00 09 (Always)
| Contains one .TIM texture
|}

== Info/Script ==

Currently unknown, takes up to ~1400 bytes from start. Unused in-game. Can be null'ied and nothing happen.

== Camera data ==

{| border="1" cellspacing="1" cellpadding="3" align="center" style="border: 1px solid black; border-collapse: collapse;"
! style="background:rgb(204,204,204)" | Offset
! style="background:rgb(204,204,204)" | Length
! style="background:rgb(204,204,204)" | Description
|-
| 0
| 2 bytes
| Number of cameras
|-
| 2
| 2 bytes
| Number of camera animations?
|-
| ?? / Camera data
| Varies
| Currently unknown
|}

Camera data contains:
# Prekeyed camera movement
# Camera zoom
# Camera FOV (horizontal and vertical)
# Orthogenical projection
# Rotation
# Special effects like earthquake
# More, unknown?
This file does not contain camera animations for victory, summons and etc.

== Geometry ==
Geometry contains groups, that contains objects. Ground plane is always 1 object, so it's easy to find geometry data by searching for "Usually starting" header as seen in info section. The group contains objects and location to every start of object

=== Group ===
{| border="1" cellspacing="1" cellpadding="3" align="center" style="border: 1px solid black; border-collapse: collapse;"
! style="background:rgb(204,204,204)" | Offset
! style="background:rgb(204,204,204)" | Length
! style="background:rgb(204,204,204)" | Description
|-
| 0
| 4 bytes
| Number of objects in group
|-
| 4
| 4 bytes
| Position of object 1
|-
| 8 / varies
| 4 bytes
| Position of next objects, if number of objects != 1
|}

=== Object ===

{| border="1" cellspacing="1" cellpadding="3" align="center" style="border: 1px solid black; border-collapse: collapse;"
! style="background:rgb(204,204,204)" | Offset
! style="background:rgb(204,204,204)" | Length
! style="background:rgb(204,204,204)" | Description
|-
| 0
| 4 bytes
| Always 01 00 01 00 / Header of object
|-
| 4
| 2 bytes
| Uint16 / number of vertices.
|-
| 6
| Number of vertices * 6
| Vertex data, short X; short Y; short Z;
|-
| 6 + (Number of vertices *6)
| (AbsolutePosition MOD 4) + 2
| Padding
|-
| varies (just after above)
| 2 bytes
| uint16 / number of triangles
|-
| varies (just after above)
| 2 bytes
| uint16 / number of quads
|-
| varies (just after above)
| 4 bytes
| padding
|-
| varies (just after above)
| number of triangles * 20
| Triangle data. If NumOfTriangles = 0, then instead of any triangle data, there's quad data.
|-
| varies (just after above)
| number of quads * 24
| Triangle data. If NumOfQuads = 0, then instead of any quad data, there's either next header 01 00 01 00, or end of group.
|}

==== Triangle ====

{| border="1" cellspacing="1" cellpadding="3" align="center" style="border: 1px solid black; border-collapse: collapse;"
! style="background:rgb(204,204,204)" | Name
! style="background:rgb(204,204,204)" | Type
! style="background:rgb(204,204,204)" | Description
|-
| F1 (A)
| uint16
| A of face indice
|-
| F2 (B)
| uint16
| B of face indice
|-
| F3 (C)
| uint16
| C of face indice
|-
| U1
| Byte
| U of first texture coordinate
|-
| V1
| Byte
| V of first texture coordinate
|-
| U2
| Byte
| U of second texture coordinate
|-
| V2
| Byte
| V of second texture coordinate
|-
| Texture related
| 2 bytes
| Texture related (?)
|-
| U3
| Byte
| U of third texture coordinate
|-
| V3
| Byte
| V of third texture coordinate
|-
| Texture related
| 2 bytes
| Texture related (?)
|-
| Red
| Byte
| Texture colourization (Red)
|-
| Green
| Byte
| Texture colourization (Green)
|-
| Blue
| Byte
| Texture colourization (Blue)
|-
| Texture ID
| Byte
| Texture ID
|}

==== Quad ====

{| border="1" cellspacing="1" cellpadding="3" align="center" style="border: 1px solid black; border-collapse: collapse;"
! style="background:rgb(204,204,204)" | Name
! style="background:rgb(204,204,204)" | Type
! style="background:rgb(204,204,204)" | Description
|-
| F1 (A)
| uint16
| A of face indice
|-
| F2 (B)
| uint16
| B of face indice
|-
| F3 (C)
| uint16
| C of face indice
|-
| F4 (D)
| uint16
| D of face indice
|-
| U1
| Byte
| U of first texture coordinate
|-
| V1
| Byte
| V of first texture coordinate
|-
| Texture related
| 2 bytes
| Texture related (?)
|-
| U2
| Byte
| U of second texture coordinate
|-
| V2
| Byte
| V of second texture coordinate
|-
| Texture related
| 2 bytes
| Texture related (?)
|-
| U3
| Byte
| U of third texture coordinate
|-
| V3
| Byte
| V of third texture coordinate
|-
| U4
| Byte
| U of fourth texture coordinate
|-
| V4
| Byte
| V of fourth texture coordinate
|-
| Red
| Byte
| Texture colourization (Red)
|-
| Green
| Byte
| Texture colourization (Green)
|-
| Blue
| Byte
| Texture colourization (Blue)
|-
| Texture ID
| Byte
| Texture ID
|}

== Texture ==

Contains one [[PSX/TIM_format|TIMs]] with various size 512x256, 673x256, 768x256 (8BPP).
Anonymous user

Navigation menu