Strange graphics file format

Started by
17 comments, last by Stainless 10 years ago

Has anyone come across a graphics file format that starts with IMF

The file extension is TGA, but it's not readable as a TGA file.

I know the short at offset 8 is the image width, and the next short is the image height.

The images are either 24 bits per pixel or 32 and are not compressed, well the file sizes don't suggest they are compressed.

A 128 by 128 32 bit image is 65,804 bytes

I have tried the obvious skip the header and load the rest as pixels, no good

Anybody come across this file format?

Advertisement

I haven't run into files like that in particular, but a bit of googling implies it may be an ImageForge file.

Please don't PM me with questions. Post them in the forums for everyone's benefit, and I can embarrass myself publicly.

You don't forget how to play when you grow old; you grow old when you forget how to play.

Some games (IL2, Theatre of War) use a format that matches what you describe. You can check with this.

Yes, that tool works so that is the correct file format.

I need to write my own loader for it though, I'll have a look at ImageForge and see if that gives me any clues.

I don't think it's related to ImageForge, just a proprietary format made for those games. Did you try stripping the header (I think it has width, height and bit depth) and reading the rest of the file as a TGA image?

I've tried reading the files in multiple ways.

Things like straight 32 bit per pixel. four bit planes one byte per pixel, etc. No luck. I'll keep hacking away.

hmmm.. I wonder if you are right, I'll read up on the TGA header

No doesn't look like it

49 4D 46 1A 31 30 00 01 80 00 80 00 01 04 04 04 04 04 04 04 04 04 02 02 04 02 02 02 01 04 04 04 02 02 02 02 04 04 04 04 04 02 04

I M F 1 |width|height|

I've never seen a header like that before, all those 4's and 2's confuse the hell out of me

have you tried working from the end of the file - e.g. file length - width * height.

If you upload the image we can have a look at it.

I've stuck one of these graphics on the project page as

2bladedmetall.tga

http://stainlessbeer.weebly.com/il2-mod-tool.html

I'm giving back to the IL2 community, a while ago I used some of their meshes for a demo (not a commercial product) and now I want to pay them back with an app that helps modders test their aircraft.

It's almost complete, I just have a couple of issues left to fix, this graphic issue is the most annoying

Any help would be gratefully received


49 4D 46 1A 31 30 00 01 80 00 80 00 01 04 04 04 04 04 04 04 04 04 02 02 04 02 02 02 01 04 04 04 02 02 02 02 04 04 04 04 04 02 04

The section after the image width and height look like flags that were OR-masked together.

"I would try to find halo source code by bungie best fps engine ever created, u see why call of duty loses speed due to its detail." -- GettingNifty

This topic is closed to new replies.

Advertisement