PDA

View Full Version : WTP format...



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?).

Macrophage
16th Sep 04, 10:07 AM
This sounds great, do you have a pic you could show us?

CLR
16th Sep 04, 10:45 AM
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?).

RSH seems to be the texture data for the army painter... I may be mistaken but after looking at some LUAs it seemed to point to that.

SvK
16th Sep 04, 1:24 PM
Nice! Good to have you here, WarHammered. I wish I knew all that file format cracking stuff.

WarHammered
16th Sep 04, 1:38 PM
RSH seems to be the texture data for the army painter... I may be mistaken but after looking at some LUAs it seemed to point to that.
You may be right about that. I totally forgot about painting and that explains why the marine textures are all grey when I viewed them.

But there is also some extra texture data in the wtp file itself, 8bit data that matches the same resolution as the texture under the chunk "DATAPTLD" which PTLD may be an acronym or an abbreviation about paint.

RSH looks like it stores the resolution of the image in it, but the DATADATA section is not easily dividable by the height.


This sounds great, do you have a pic you could show us?

I don't know how legal that would be to distribute their textures on the web, I was actually going to try and finish the viewer, so others can look at the images, or make a converter so others can convert the images to another format.

Spooky
16th Sep 04, 2:13 PM
When I get a moment I will take a look at the graphics file formats for DoW - It only took me a day or so to do the IC and HW2 ones, I cannot imagine the DoW ones being any different... ;)