Changes

Jump to navigation Jump to search

FF8/FileFormat magfiles

708 bytes added, 05:25, 23 May 2019
m
19 revisions imported
First, recognize file:
1.Header must be 8 bytes null!! EDIT: Usually, but there are meshes without 8 bytes null header. Don't be afraid Jump to test them. pointer at 0xC [Global]
2.Jump to This int indicates pointer at 0xC [Global]count. Example: 10 00 00 00 is 16 pointers
3.This int indicates pointer count. Example: 10 00 00 00 is 16 pointers 3a. If pointer is 00 00 00 00, just ignore it and move forward
4.After noting all pointers that are not 00 00 00 00 (therefore inspecting Count*4 bytes) just jump to selected one [Relative jump from count int]
Example: 09 00 9f 01 means there's 9f 01 (415) polygons of type 0x9. Therefore: 28*415=11620 bytes to next polygon type or vertices if FF FF FF FF.
==Magic.fs and Battle.fs MAG environment GF objects==
GF Environment (stages like Cerberus gate; Alexander backdrop and etc.) geometry contains many polygon types (sic!). Every single polygon type is different than other.
6. There's no sizes, so if there's another texture after the one you're getting, then subdivide next texture position from current position to get size and determine texture resolution. If it's the last texture, then it gets a bit tricky, as in many ways the file is not ending with texture but SCOT for example..
 
Texture is '''8BPP''' (does not contain palette/monochromatic) (one byte is all three channels in 24RGB manner)
 
'''Texture resolution is based on size:'''
 
 
{| border="1" cellspacing="1" cellpadding="3" align="center" style="border: 1px solid black; border-collapse: collapse;"
! style="background:rgb(204,204,204)" | Texture byte size
! style="background:rgb(204,204,204)" | Texture final resolution
|-
| 0x2000
| 64x64 (or 32x32)*
|-
| 0x4000
| 128x128 (or 64x64)*
|-
| 0x8000
| 256x256 (or 128x128)*
|-
| 0x10000
| 256x256
|}
GFs uses higher texture resolution, for example 0x2000 is 64x64 instead of 32x32, but many magic texture like fire effect animation atlas texture is using the lower resolution (the one with asterisk *, for example 0x2000 for fire atlas animation texture it's 32x32 instead of 64x64)
 
==SCOT==
Related to sound transition effect. Structure is completely unknown.

Navigation menu