Berserk (*.MTP2)
Posted: Sun Apr 08, 2012 4:35 am
I'm trying to extract texture data from the mtp2 files, but I'm having a hard time extracting the individual texture data from the archive or texture package.
seems my offset and size calculations are wrong, and I don't know where to start on how to analyze the texture data
Here's are my structures
mtp_header { // 16bytes
byte[4] magic, "MTP2 "
byte[4] buffer offset
byte[4] buffer size
byte[2] unknown, always 1
byte[2] count
}
texture_entry { // 68bytes
byte[4] offset * 0x0100
byte[4] unknown, always 0x02
byte[2] compression??, usually 0x13 or 0x14
byte[2] unknown, usually 0x00
byte[4] unknown, value seems progressive
byte[12] padding? all 0's
byte[2] texture height
byte[2] texture width
byte[4] size * 0x0100
byte[16] padding? all 0's
string[16] texture name
}
In the samples I've included some textures dumped from the PS2 emu. may help to decipher the texture data
seems my offset and size calculations are wrong, and I don't know where to start on how to analyze the texture data
Here's are my structures
mtp_header { // 16bytes
byte[4] magic, "MTP2 "
byte[4] buffer offset
byte[4] buffer size
byte[2] unknown, always 1
byte[2] count
}
texture_entry { // 68bytes
byte[4] offset * 0x0100
byte[4] unknown, always 0x02
byte[2] compression??, usually 0x13 or 0x14
byte[2] unknown, usually 0x00
byte[4] unknown, value seems progressive
byte[12] padding? all 0's
byte[2] texture height
byte[2] texture width
byte[4] size * 0x0100
byte[16] padding? all 0's
string[16] texture name
}
In the samples I've included some textures dumped from the PS2 emu. may help to decipher the texture data