- Tue Sep 20, 2011 2:17 am
#42412
I was able to use PSicture last night to find some pictures. Basically, you need to know where the start of an image is using a HEX editor. The number of palettes is in a DWORD ([pal] 00 00 00) which after that comes the image data. On the first address right after the last 00 in the DWORD, that's the address you need to use. All images are 2048 byte aligned, so to skip to the next image, you need to use the equation 256*128+2048 and add that to the decimal address you just used. Well, that one works for the following example, anyways.
In a HEX editor, go to address 10B804. You'll see that the beginning of the address is "10 00 00 00" which is the DWORD that contains the palette. Translate the HEX 10 to get the decimal number of 16. That's how many palettes there are - 16. Now, using this newfound knowledge, we know so far that:
Address = 1095684
Bits per pixel = 4 (this is what Driver uses)
# Palettes = 16
Still missing some data. For the image size, use 256 X 256. This may work for every image, but this is unknown.
To calculate the offset (which is very important) use the equation 2048-4-32*[pal], so basically, in this case, we take 2044 and subtract 32*16 (which is 512) to get the offset of 1532.
Now we know that -
Address = 1095684
Image size = 256 x 256
Bits Per Pixel = 4
Offset = 1532
# Palettes = 16
(DO NOT CHECK "PALETTE AFTER IMAGE")
Punch those in, and if all goes according to plan, you can use F7 and F8 to scan through each of the palettes from left to right.
About the 2048-byte aligned thing, basically use the equation to get 34816 and ADD it to the address 1095684 to get the address of 1130500. Use your HEX editor to go to this address and figure out the number of palettes. If you go into PSicture only to find out there's no images there, you probably ran into the end of an image. Same thing for me.
I have a feeling 256*128-2048 is multiplying the image size and subtracting 2048 to align the next image as 2048-byte aligned. But alas, maybe Jeff can reiterate on this a bit more. This is, afterall, what he taught me last night. Yes, PS1 LEV files are being looked into, but no guarantees!
I am not the one you should ask for help. I only know the basics, lol.
Have fun!
Need help with something? PM Me!
Formerly known as CarLuver69 / Dr. Doom
