Next Generation Emulation banner

1 - 14 of 14 Posts

·
"Insert witty title here"
Joined
·
1,049 Posts
Discussion Starter #1
What would be the best way to go about deciphering a file format that there is no information on? I know the file is an image file, I know where the signature is, and I know where the width and height of the image are. How can I find some more info on this format? I have a way of viewing the image and I can use a hex editor :). I could just go through the file changing every byte and seeing how it affects the image, but is there another way I could do it to make it easier?
 

·
Emu author
Joined
·
1,488 Posts
bcrew1375 said:
What would be the best way to go about deciphering a file format that there is no information on? I know the file is an image file, I know where the signature is, and I know where the width and height of the image are. How can I find some more info on this format? I have a way of viewing the image and I can use a hex editor :). I could just go through the file changing every byte and seeing how it affects the image, but is there another way I could do it to make it easier?
When you say you have its signature are you referring to the first 4 bytes, the "magic string" of the file? If you can view it whatever's opening it can obviously figure out what it is...

Tell us more about it, ie if you do have the magic string tell us that, also tell us its width/height vs. size and what the image looks like (save it as something else maybe and post it) so we can get a good idea of dimensions vs. overall size so we can try to see how compressed it is (if at all).

- Exo
 

·
"Insert witty title here"
Joined
·
1,049 Posts
Discussion Starter #4
Okay. I'm not sure if it's alright to post about because it's an Xbox image file, and of course the only way I could of got that was through modded Xbox. It would probably be illegal to post even an image file on here. Anyway, it's the mission clear images from Guilty Gear X2 Reloaded. I'm positive it's compressed, the images are 640 x 480 and about 150K. I want to figure out the format so I can convert them and use them on a PC.

I'm not really sure if what I call the signature is the signature at all. It's basically the bytes at the beginning that don't change. I noticed some of the bytes were 640 and 480, I immediately assumed this was the width and height. I changed it, and put the file back in the game, and I was correct. So, I consider everything before that the signature. I looked at some common image formats, but it doesn't seem like any of them.
 

·
Transcended
Joined
·
1,416 Posts
Well, unfortunately, it's a pain to decipher an unknown image format. The best way of going about it is through a disassmebler... but tracing the game to see how it deciphers the format is illegal. And I don't know if such a disassembler exists.
 

·
Emu author
Joined
·
1,488 Posts
bcrew1375 said:
Okay. I'm not sure if it's alright to post about because it's an Xbox image file, and of course the only way I could of got that was through modded Xbox. It would probably be illegal to post even an image file on here. Anyway, it's the mission clear images from Guilty Gear X2 Reloaded. I'm positive it's compressed, the images are 640 x 480 and about 150K. I want to figure out the format so I can convert them and use them on a PC.

I'm not really sure if what I call the signature is the signature at all. It's basically the bytes at the beginning that don't change. I noticed some of the bytes were 640 and 480, I immediately assumed this was the width and height. I changed it, and put the file back in the game, and I was correct. So, I consider everything before that the signature. I looked at some common image formats, but it doesn't seem like any of them.
Could you give us an idea of what it looks like (is it a lot of space that's the same color or is it highly veried)? Do you notice any lossy artifacting when it's displayed? Finally, what are the first four characters, in letters...

If your way of viewing it is with the XBox itself (and not with a file on your computer, like I originally assumed) then it might be impossible to mod it. Still, chances are that it's using a well known file type...

- Exo
 

·
"Insert witty title here"
Joined
·
1,049 Posts
Discussion Starter #7
Alot of the picture seems black. I can't really tell if there are any artifacts, the image is on a TV screen and so is kind of blurry. These are the hex codes before the width and height: 10 00 00 00 FF FF FF FF FF FF FF FF FF FF FF FF 01 00 20 00 08 00. So there really aren't any letters, or anything. If it's not against the rules, which I doubt it isn't, I'll post the image file here.
 

·
Emu author
Joined
·
1,488 Posts
So it looks like there isn't a "magic string", and thus it's probably not a "normal" format. However, if much of it is black then it might be RLE encoded or some other lossless format (or else its size would probably be much smaller). Naturally the format is little endian (since it's x86)... those FF's are probably filler for reserved space.

If it's RLE or some variant thereof it can probably be reversed. You can send me the file if you want (see my profile).. it'd be especially helpful if you could also send a screencap of it. Do you have a TV card? Also, do you have any other image files that can be used for comparison..

As far as disassembling goes, you could probably use any old x86 disassembler, although you'll end up disassembling XBE headers and whatnot in addition to the code you're interested in.

- Exo
 

·
"Insert witty title here"
Joined
·
1,049 Posts
Discussion Starter #9
Well, the thing is, I kinda wanted to figure out the format on my own. Sort of a little project. It's just I'm not quite sure how to start. Is the best course of action really to just alter the file and see how it changes when displayed? This would be quite tedious, considering I would constantly have to reset my Xbox. Though, if that is the only way, so be it :|.
 

·
Emu author
Joined
·
1,488 Posts
You can try doing that to see what happens but you'll probably drastically alter the image. It would be a good test to see if it's RLE however - if it's traditional RLE and you change some value in the middle the first part of the image will probably look the same.

It really helps to know about existing compression algorithms.

- Exo
 

·
Registered
Joined
·
1,168 Posts
I think it's a good start to assume this file is in some standard format. Why should anyone bother to create yet-another-image-format when you have lots of existing formats? @Kraelis: Why do you think it's illegal? DMCA and stuff? How do you think emulators are made?
 

·
"Insert witty title here"
Joined
·
1,049 Posts
Discussion Starter #12
Yes, reverse engineering for learning purposes is legal. It's using the code as your own that is illegal. I have a very strong feeling this file is RLE. Unfortunately, I haven't made any kind of new discovery yet. :(
 

·
Transcended
Joined
·
1,416 Posts
Well legality is a fuzzy matter. The learning clause covers a lot, but it's a conflict as to reconciling the EULA. Read the EULA carefully. It's not your code, therefore, you have no right to be disassembling it. Note I used the word disassembling. Reverse engineering is a bit vague.

Good luck though. Working backwards is a fun, fun process. :)
 

·
Banned
Joined
·
177 Posts
More than likely a high-bit encryption that when unencrypted is nothing more than a bmp. Problem is finding the algorithm. I'll try this and see what i can come up with sounds fun.
 
1 - 14 of 14 Posts
Top