Wednesday, March 10, 2010

Latest LZO Compression implemented in Java

I have ported the Mini LZO (version 2.03) compression utility in 'c' to pure java.

Initial version of the port is here.

You can try the example using this sample program

You may refer original Java-LZO version (done in way back 1999) here. In the Original only decompression is implemented.

Current ported java-minilzo-jar has implemented following methods: compression, decompression and decompression_safe. At present Compression & decompression of zero-filled-data and random-data is working properly. I will be adding more utilities and API for end-users shortly.

Many many thanks to Markus F.X.J. Oberhumer for his excellent minilzo.c (which is the base for current java implementation)

4 comments:

  1. Cool! Not to rush or anything, but got any benchmarks? :)

    ReplyDelete
  2. I am planning to add them 1/2 months.

    ReplyDelete
  3. When decompressing any input packet that may be large e.g., 90000 bytes, the decompress will fail giving ArrayIndexOutOfBounds Exception. We have seen this for smaller input buffers too. The output buffer is allocated for 20x more than the input buffer but still it does not help.. Any ideas..? For smaller packets, it works ok...

    ReplyDelete