PDA

View Full Version : ...please try my program...



Sebastiani
07-15-2002, 11:42 PM
Will someone try my file-compression program? It's free! :p You can even call it from another program, making it easy to incorperate into GUI downloads. Anyway, please try it!
To compress files, simply drag and drop as many as necessary onto the .exe's icon. Decompressing works the same way. The compressed files will have a ".pkt" extension and both the decompressed and compressed files recieve a "(PK)" stamp at the beginning of the filename to allow them to coexist with the originals.
The most remarkable compressions will result from bitmaps. The exceptions are bitmaps of photographic images, since these have more random fluctuations in their byte patterns.
Interestingly, I used the above scenario (calling from another program) to "unpack" a windows program. It originally required the download of about 130MB of graphics files. These were compressed down to about 0.75MB. My uncle downloaded the entire program from a 56K modem in under 2 minutes! This saved several hours of downloading!

toaster
07-16-2002, 12:37 PM
what compression algorithm are you using?

Unregistered
07-16-2002, 01:03 PM
you think i believe hat crap?

Sebastiani
07-16-2002, 05:56 PM
The algorithm is my own and, admittedly, simple. Basically, the program starts at the first byte and checks to see if the adjacent byte is identical. The process continues on like this, gradually widening the comparing buffer till a match is found. If not, the buffer falls back to one-byte's width and the comparison starts at byte two! After the compression is complete, the size of the new buffer is double-checked with the original to guarantee the former is smaller than the latter.
I am no math genius, so it was the most logical way to do it.

face_master
07-16-2002, 06:39 PM
I could only get it to work on some bitmap files that I made so heaps of the adjacent pixels were here same. I used 3 different colours all lined up and it more than halved the 14k bitmap.

Sebastiani
07-16-2002, 08:21 PM
A good benchmark is the WinZip program. Side by side, mine doesn't do too bad. But of course, Winzip usually outdoes me a bit! Still, like I said you can call it in other programs, a nice feature that Winzip doesn't do.

Betazep
07-16-2002, 09:51 PM
It is a very nice application. I am impressed.

drharv
07-16-2002, 10:08 PM
Am I the only one that finds it ironic that your compression program is downloaded as a zip? Not trying to make fun, I think it's awesome that you wrote this. Just thought it was a little humorous. :D

Sebastiani
07-16-2002, 10:24 PM
Hey thanks for the comment, Beta :) But honesty comes first :p

And yes, I did notice that little bootstrap irony too :D

Please let me know if you have any problems with it.

doubleanti
07-16-2002, 10:26 PM
sounds like RLE to me... try it with other data as input... eg, random data... or at least more random than what i assume you are using [blank or bytewise repeatative bitmaps]...

Sebastiani
07-16-2002, 11:35 PM
That's just the thing. In essence the function looks at things rather flatly, and due to this, the compression is weak on photos, complex bitmaps, etc. I will experiment on some "deeper" analysis techniques soon though. I won't be satisfied till I beat Winzip! Oh, and how might I make the process run faster? I am using register variables (well, ASKING for them, that is ;) ) and running as efficiently as possible. For instance: at first I would iterate through an entire chunk to see if it was identical with the comparing chunk. Then I tripled the speed by comparing the first and last bytes of the two FIRST. Still, when processing huge photos, several seconds are needed and then I find I couldn't make it smaller. ( note: there is an overhead of 12 bytes for each "sub-compress").

Unregistered
07-20-2002, 10:28 PM
>It originally required the download of about 130MB of graphics files. These were compressed down to about 0.75MB

i dont believe this part

Dual-Catfish
07-20-2002, 10:58 PM
|Packet.exe - Application Error |x|
| |
| The instruction at "0x00405930" refrenced memory |
| at 0x02BA0000". The memory could not be "read". |
| |
| Click on OK to terminate the program |
| Click on CANCEL to debug the program |
| |
| +---------+ +---------+ |
| | Ok | | Cancel | |
| +---------+ +---------+ |
+--------------------------------------------------------+