List of compression types which I never want to hear about again: {LZW, Carmack}
It is really awful when documentation is inaccurate, inconsistent, and confusing. I did finally manage to navigate and experiment enough with the gamemaps format to make it work! To start out, I made things easier for myself in the future: I changed the compression/decompression algorithms to take in a reference to an output stream instead of creating a new stream and returning that.
Something I missed when reading the documentation was that the address mentioned by a Cramack far pointer needs to be multiplied by two because it's in words. Two of the three documents I read made no mention of that and the one that did, did so very unobviously. With that done, I was able to load and resave gamemaps and maphead successfully!
Next up is Galaxy graphics, which includes Huffman compression. I have absolutely no idea how that works, but I have set up some nice interfaces and classes for the strange chunk handling.
No comments:
Post a Comment