WarHammered
16th Sep 04, 10:02 AM
I've figured some things out enough to make a test viewer for the wtp format. Assuming of course there is not already tools from HW that do the same thing.
It's a chunky format, that starts with an 12 char identifier "Relic Chunky", followed by 3 dwords that I am not sure what they are for, maybe version information about the format.
Each chunk is composed of an 8 char type identifier, an unknown dword (maybe version number for the chunk), a dword representing the size of the data in the chunk, a dword for a string length followed by a variable size string (based upon the string length), and then finaly the actual data. And the chunks can have subchunks in its data.
The root chunk in WTP files appears to be "FOLDTPAT". And its children chunks are "DATAINFO", "DATAPTLD", "FOLDIMAG", and "DATAPTBN". "DATAINFO" has what appears to have the width and height but I am not sure if this is the main width and height or general values (there is another width and height later on). "DATAPTLD" appears to be some kind of 8bit image data, but its not the main data. The main data is in "FOLDIMAG", and FOLDIMAG has 2 subchunks "DATAATTR", and "DATADATA". "DATAATTR" has 3 dwords for its data which I would guess the first 2 are width and height, and the last I don't know, it could be a mode or something (I've only seen it as 0x00000001). "DATADATA" has the actual RGBA values. The whole thing looks like this :
FOLDTPAT
|-->DATAINFO
|-->DATAPTLD
|-->FOLDIMAG
| |-->DATAATTR
| |-->DATADATA
|-->DATAPTBN
I was able to create a quick hack win32 WTP viewer, but I think I'm a quite a ways from creating an image converter (helpful to mod makers).
I'll probably look at the other formats as well "rsh" (looks almost like an image format?), "whm" (model, skeleton, and anims?), "whe" (events?).
It's a chunky format, that starts with an 12 char identifier "Relic Chunky", followed by 3 dwords that I am not sure what they are for, maybe version information about the format.
Each chunk is composed of an 8 char type identifier, an unknown dword (maybe version number for the chunk), a dword representing the size of the data in the chunk, a dword for a string length followed by a variable size string (based upon the string length), and then finaly the actual data. And the chunks can have subchunks in its data.
The root chunk in WTP files appears to be "FOLDTPAT". And its children chunks are "DATAINFO", "DATAPTLD", "FOLDIMAG", and "DATAPTBN". "DATAINFO" has what appears to have the width and height but I am not sure if this is the main width and height or general values (there is another width and height later on). "DATAPTLD" appears to be some kind of 8bit image data, but its not the main data. The main data is in "FOLDIMAG", and FOLDIMAG has 2 subchunks "DATAATTR", and "DATADATA". "DATAATTR" has 3 dwords for its data which I would guess the first 2 are width and height, and the last I don't know, it could be a mode or something (I've only seen it as 0x00000001). "DATADATA" has the actual RGBA values. The whole thing looks like this :
FOLDTPAT
|-->DATAINFO
|-->DATAPTLD
|-->FOLDIMAG
| |-->DATAATTR
| |-->DATADATA
|-->DATAPTBN
I was able to create a quick hack win32 WTP viewer, but I think I'm a quite a ways from creating an image converter (helpful to mod makers).
I'll probably look at the other formats as well "rsh" (looks almost like an image format?), "whm" (model, skeleton, and anims?), "whe" (events?).