LucasForums

LucasForums (http://www.lucasforums.com/index.php)
-   SCUMM (http://www.lucasforums.com/forumdisplay.php?f=363)
-   -   need help on image compression (http://www.lucasforums.com/showthread.php?t=206064)

phedon 12-02-2010 06:44 AM

need help on image compression
 
hi,
I need informations about the image compression in old LA games like MI2, FOA.
Could someone please describe the SMAP block format?

offset type
0 dword ("SMAP")
4 dword (size of block)

What is the rest? What are stripe offsets? Where do I find them?
I think, if the room has a size of 320x200 pixel, there are 320 / 8 = 40 single stripes I have to process, is this correct?
The informations given in (link) ain't completely clear for me, as they cover all formats, the old (BM/PA) and the new ones (RMIM/CLUT). I tried to use the given informations on an image, but this didn't make sense.
Could someone please give me an example ?
Like "how to decode the background-image of room 1 (Indy's office) in FOA"?

best regards
phedon



Btw: I know how to handle the palette (CLUT).

bgbennyboy 12-02-2010 04:00 PM

You need the old inside the engine article:
http://goblin.cx/scumm/scummrev/articles/inside.html

jestar_jokin 12-02-2010 10:26 PM

I have written a simple tool to decompress background images in SCUMM V5 games, you can find it on my website (called "SCUMM Image Encoder (mi2img)"). It has Python source code available. SCUMM V5 has multiple methods for compressing the backgrounds. It only compresses in the "lossless" format.

It requires certain blocks extracted from the resource file, you can get these blocks using either ScummPacker (also on my site) or scummrp (from elsewhere).

http://www.jestarjokin.net/

Also, check out the source code for the incomplete tool ScummEx, available in the ScummVM repositories.

phedon 12-03-2010 04:59 AM

Thanks alot!
While looking through the data, things became clear instantly ;)

header dword
size dword
offset stripe1 data word
offset stripe2 data word
[...]
offset stripeX data word

stripe1 data
[..]
stripe2 data
[..]
stripeX data
[..]

Sometimes one is just too dumb, not seeing the hand in front of your face :)

regards
phedon


All times are GMT -4. The time now is 09:05 PM.

Powered by vBulletin®
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
LFNetwork, LLC ©2002-2011 - All rights reserved.