CDF: Difference between revisions
No edit summary |
No edit summary |
||
Line 26: | Line 26: | ||
The only issue may be certain sectors that are in a different mode so the data portion of the sector may be a different length. Scanning a raw dump of the disc might work out better as certain data types such as FMV or audio | The only issue may be certain sectors that are in a different mode so the data portion of the sector may be a different length. Scanning a raw dump of the disc might work out better as certain data types such as FMV or audio | ||
may use this other CD-XA mode so the structure of the sector is different. My tool will need to be able to handle both paths. One where you scan the CDF directy but may have to skip any file types that require sectors with data greater than 2048 and one that can scan a bin file and handle those special cases. I still need to find an index for the game. The HED file and PE_DISK.01 and .02 are byte-for-byte identical on each disc. | may use this other CD-XA mode so the structure of the sector is different. My tool will need to be able to handle both paths. One where you scan the CDF directy but may have to skip any file types that require sectors with data greater than 2048 and one that can scan a bin file and handle those special cases. I still need to find an index for the game. The HED file and PE_DISK.01 and .02 are byte-for-byte identical on each disc. | ||
TEMP: 2023/1/24 | |||
Some additional notes before a re-write. The structure of the index for these are not based on the LBA of the disc but offsets are based location inside the file itself. STAGE0 and it's separate header index entries start from 0 for example. Others have the header embedded at the start of the file. There is more than just normal indexes as there may be folders and then a separate list of files that may be listed as streaming. This requires more looking into but could be due to streaming may be video related that may use a different reading mode and sector size. | |||
== See Also == | == See Also == | ||
[[HED]] | [[HED]] |
Latest revision as of 02:48, 25 January 2023
Used in the following games:
- Parasite Eve II (PSX)
Note: Formats are aligned to sectors. Any change to files may require full rebuild of whole image. This is typical of PS1 games.
There may be a pattern for how files are stored and accessed. At the start of each sector, after the CD-XA header, if the sector is the start of a new file, there will be 16-bytes in front of it first. First 4-bytes with a random number. Then a single byte which represents how many sectors this file will occupy. The rest is zeroed out. With this, I was able to write a program that would go sector-by-sector looking for this header than matched. I was able to extract 1,049 background images in full.
File Formats | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Value | Temp | Occurrences (Disk1) | Occurrences (Disk2) | |||||||||||
05FF0008 | BS Format (Backgrounds) | ? | ? | |||||||||||
07FF0008 | String (1byte)? | ? | ? | |||||||||||
02010008 | Unknown | ? | ? | |||||||||||
01010008 | Unknown | ? | ? | |||||||||||
06010008 | Unknown | ? | ? |
Temp: 2018/03/05 From what I have gathered, CDF does not have any type of index in itself however each entry has an identifier at the start of the data portion of the sector that is 16 bytes in length. This contains a unique identifier that is used to determine the content type followed by at least 1 byte that indicates how many frames the data occupies. This goes along with my original findings long ago but now it seems more clear. The only issue may be certain sectors that are in a different mode so the data portion of the sector may be a different length. Scanning a raw dump of the disc might work out better as certain data types such as FMV or audio may use this other CD-XA mode so the structure of the sector is different. My tool will need to be able to handle both paths. One where you scan the CDF directy but may have to skip any file types that require sectors with data greater than 2048 and one that can scan a bin file and handle those special cases. I still need to find an index for the game. The HED file and PE_DISK.01 and .02 are byte-for-byte identical on each disc.
TEMP: 2023/1/24 Some additional notes before a re-write. The structure of the index for these are not based on the LBA of the disc but offsets are based location inside the file itself. STAGE0 and it's separate header index entries start from 0 for example. Others have the header embedded at the start of the file. There is more than just normal indexes as there may be folders and then a separate list of files that may be listed as streaming. This requires more looking into but could be due to streaming may be video related that may use a different reading mode and sector size.