Difference between revisions of "ARC"
Jump to navigation
Jump to search
(Created page with "Category:File formats This page documents the format of ARC. == Overview == ARC files are archives. Containers of files compressed with LZ-10 (more compression methods migh...") |
|||
Line 22: | Line 22: | ||
| 0x00C || 4 || uint32 || File's length | | 0x00C || 4 || uint32 || File's length | ||
|- | |- | ||
− | | 0x010 || 4 || uint32 || File table offset (from the beginning of the file) | + | | 0x010 || 4 || uint32 || [[ARC#File_table|File table]] offset (from the beginning of the file) |
|- | |- | ||
− | | 0x014 || 4 || uint32 || | + | | 0x014 || 4 || uint32 || [[ARC#File_table|File table]] length |
|- | |- | ||
− | | 0x018 || 4 || uint32 || | + | | 0x018 || 4 || uint32 || [[ARC#Files_data|File table]] offset |
|} | |} | ||
Line 48: | Line 48: | ||
* First two nodes in the file table are ‘null’ and ‘.’ both have compressed file length of 7. | * First two nodes in the file table are ‘null’ and ‘.’ both have compressed file length of 7. | ||
− | === | + | === Files Data === |
* Each file is compressed using LZ-10. (Starts with 0x10 and followed by uint24 of the uncompressed file size). | * Each file is compressed using LZ-10. (Starts with 0x10 and followed by uint24 of the uncompressed file size). | ||
* Each file's end is padded to 0x10 besides the last one which ends with EOF. | * Each file's end is padded to 0x10 besides the last one which ends with EOF. |
Revision as of 19:20, 29 November 2012
This page documents the format of ARC.
Overview
ARC files are archives. Containers of files compressed with LZ-10 (more compression methods might be available).
This is very similiar to NARC (the DS archives).
ARC header
Offset | Size | Type | Description |
---|---|---|---|
0x000 | 4 | char[4] | Magic Number 'darc' |
0x004 | 2 | uint16 | Endianess (=0xFFFE: Little) |
0x006 | 2 | uint16 | Header's length |
0x008 | 4 | uint32 | Unknown (= 0x01000000 ?) |
0x00C | 4 | uint32 | File's length |
0x010 | 4 | uint32 | File table offset (from the beginning of the file) |
0x014 | 4 | uint32 | File table length |
0x018 | 4 | uint32 | File table offset |
File table
The file table starts at 0x01C.
Each file struct consists of 3 uint32:
Offset | Size | Type | Description |
---|---|---|---|
0x00C | 4 | uint32 | Compressed file name offset (from the end of the table, padded to 0x10)
if (MSB is high) then this is a folder (i.e. first two nodes 'null' & '.') |
0x004 | 4 | uint32 | Compressed file offset |
0x008 | 4 | uint32 | Compressed file length |
* First two nodes in the file table are ‘null’ and ‘.’ both have compressed file length of 7.
Files Data
* Each file is compressed using LZ-10. (Starts with 0x10 and followed by uint24 of the uncompressed file size). * Each file's end is padded to 0x10 besides the last one which ends with EOF.