MaxCoderz

for your 1 bit pleasure!

All times are UTC




Post new topic Reply to topic  [ 10 posts ] 
Author Message
PostPosted: Thu 06 Jan, 2005 7:20 am 
Offline
Maxcoderz Staff
User avatar

Joined: Wed 15 Dec, 2004 6:06 am
Posts: 579
Location: Chicago!
I've just ported the APack decompressor to Z80. The size of the decompressor is exactly 250 bytes large (about half the size of pucrunch decompressor), and the compression rates provided by APack are often better than Pucrunch!

For example, the game plus chapters of The Verdante Forest are about 70k in size. Apack gets it down to 41.3k, and Pucrunch gets it down to 40.7k. So pucrunch wins in one case, but...

Other games (like Joltima and Dying Eyes) favor Apack over pucrunch. Dying eyes gets 500 bytes smaller if compressed with Apack instead of Pucrunch, while Joltima gets 250 bytes smaller.

Here's a sample program that merely draws a picture, but it also includes the full decompression code and compression tool.
http://home.comcast.net/~alanweiss3/dwedit/files/apack_demo.zip

_________________
You know your hexadecimal output routine is broken when it displays the character 'G'.


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu 06 Jan, 2005 8:06 am 
Offline
Maxcoderz Staff
User avatar

Joined: Thu 16 Dec, 2004 10:06 pm
Posts: 4095
Location: I cant seem to get out of this cryogenic chamber!
Wow, nice work DWedit, this might come in handy :).

_________________
"My world is Black & White. But if I blink fast enough, I see it in Grayscale."
Image
Image


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu 06 Jan, 2005 9:31 am 
Offline
Sir Posts-A-Lot

Joined: Sat 18 Dec, 2004 3:38 am
Posts: 228
Have you tested it on uncompressed highly-redundant levelsets yet? I'm wondering if it could be used as a RLE replacement...


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu 06 Jan, 2005 10:02 am 
Offline
Maxcoderz Staff

Joined: Fri 17 Dec, 2004 5:33 pm
Posts: 790
Location: On the dark side of the moon.
Will you be implementing this in COS or is it for individual programmers? A method which get's TVF down by 30k is 8) .

_________________
"They say that sea was created by a man named Maarten Zwartbol, a long time ago...." - Duck, an old Corbin version


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu 06 Jan, 2005 10:17 pm 
Offline
Calc Wizard
User avatar

Joined: Fri 17 Dec, 2004 10:22 pm
Posts: 745
Location: Wandering around in the Jungle...
Wow nice Dwedit! I can certainly use this! :D

_________________
The Revolution is here...


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Tue 11 Jan, 2005 10:16 pm 
Offline
Regular Member

Joined: Tue 11 Jan, 2005 10:10 pm
Posts: 136
Location: No longer in the Midwest... now in Seattle
Cool. Can APack be used to decompress arbitrary offsets in the bitstream, (ie: like my on-the-fly Huffman routines) or is it adaptive? I couldn't find any papers on the algorithm and don't feel like reading code at the moment.


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Tue 11 Jan, 2005 11:59 pm 
Offline
Maxcoderz Staff
User avatar

Joined: Wed 15 Dec, 2004 6:06 am
Posts: 579
Location: Chicago!
It's LZ based, and it works by storing references to data that has occurred previously in the file.

While decompressing, the entire output file must be intact up to the current decompression pointer.

You can also overlap the input file with the output file, just as long as the output is written before the input, and the output never overwrites the current input file position. I used that on the GBA to run big roms in pocketnes.

Apack uses some crazy hybrid of a bit stream, and byte aligned data. It makes reading bytes faster, since they are always aligned.

From what I see, an uncompressed byte that has not occurred within 15 bytes back is encoded with 9 bits, while an uncompressed byte that has appeared within 15 bytes back is encoded with 7 bits. This is exculding all the LZ compression stuff it also does.

_________________
You know your hexadecimal output routine is broken when it displays the character 'G'.


Top
 Profile  
Reply with quote  
PostPosted: Fri 15 May, 2009 12:49 pm 
Offline
New Member

Joined: Sun 09 Nov, 2008 1:56 pm
Posts: 67
sorry for the necropost :excited: , but the site is down... and i cant seem to find the program on ticalc or google

i may use this to compress supaplex levels (RLE compresses by about 62% (21 possible tiles), i need 80...)


Top
 Profile  
Reply with quote  
PostPosted: Fri 15 May, 2009 5:33 pm 
Offline
Maxcoderz Staff
User avatar

Joined: Thu 16 Dec, 2004 10:06 pm
Posts: 3064
Location: Croydon, England
web.archive.org is your friend.


Top
 Profile  
Reply with quote  
PostPosted: Sat 16 May, 2009 10:27 am 
Offline
Maxcoderz Staff
User avatar

Joined: Wed 15 Dec, 2004 6:06 am
Posts: 579
Location: Chicago!
Now rehosted on my domain:
http://www.dwedit.org/files/apack_demo.zip

Also attached here too.


Attachments:
apack_demo.zip [28.98 KiB]
Downloaded 124 times

_________________
You know your hexadecimal output routine is broken when it displays the character 'G'.
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 10 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 6 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB ® Forum Software © phpBB Group | DVGFX2 by: Matt