Ekona icon indicating copy to clipboard operation
Ekona copied to clipboard

✨ Implement LZSS decoder, LZSS encoder and RLE decoder

Open pleonex opened this issue 1 year ago • 0 comments

Implement compression and decompression for some of the BIOS built-in compressions:

  • LZSS: decompress and compress
  • RLE: decompress

TODO:

  • [ ] Unit tests for RLE
  • [ ] Compression for RLE
  • [ ] Update documentation (and README)

Part of #29

Quality check list

  • [ ] Related code has been tested automatically or manually
  • [ ] Related documentation is updated
  • [x] I acknowledge I have read and filled this checklist and accept the developer certificate of origin

Acceptance criteria

  • Compress and decompress LZSS files.
  • Compress and decompress RLE files

Follow-up work

  • Implement Huffman compressions
  • Implement BLZ compressions
  • Implement LZ11 compression

Example

// Compress a Stream
var encoder = new LzssEncoder();
using Stream outputStream = encoder.Convert(inputStream);

// Or pass the output in the constructor
new LzssEncoder(outputStream).Convert(inputStream);

Same for the LZSS decompressor LzssDecoder or the RLE decompressor RleDecoder.

pleonex avatar Oct 13 '24 10:10 pleonex