Page 1 of 1
Make your own Compression Libraries
Posted: Mon Feb 11, 2013 10:02 am
by walker7
If you have ever used the Sonic Data Compression Tool before, you will notice that there are four .dll files, one for each type of compression (Kosinski, Nemesis, Enigma, and Saxman) that come along with the main application that you use to compress/decompress files.
If you wanted to build a similar tool for your own compression formats, what program will need to use to make your .dll files, as well as making the main application?
A similar tool could also be made and used to transform data (e.g. for 8*8 tiles, you could choose to have all instances of one nybble replaced with another, thereby replacing the corresponding pixels' color).
Posted: Mon Feb 11, 2013 11:22 am
by TmEE co.(TM)
Making a DLL is matter of setting a right compiler flag so it would make a DLL instead of an EXE.
Rest is up to the programmer to write and create interfaces for.
Windows Forms Applications
Posted: Tue Feb 12, 2013 11:23 am
by walker7
The main application of Sonic Data Compressor seems to be made of a Windows Forms Application. You can make these from Microsoft Visual C++.
You can write a compressor and decompressor as a C++ program, and then run those programs with the push of a button on the main application, just like the Sonic Data Compressor.
Re: Windows Forms Applications
Posted: Fri Feb 15, 2013 12:33 am
by powerofrecall
walker7 wrote:The main application of Sonic Data Compressor seems to be made of a Windows Forms Application. You can make these from Microsoft Visual C++.
You can write a compressor and decompressor as a C++ program, and then run those programs with the push of a button on the main application, just like the Sonic Data Compressor.
You're most of the way there. Any windows compiler can put out a dll, I'd recommend one of Microsoft's Visual Studio Express products. You will also need to know what functions the main application is going to import from a compression dll. Probably one for compression and one for decompression. You can either consult documentation for Sonic Data Compressor (maybe it will mention the functions the dll needs to export, I'm not familiar with it) or just throw the main application in IDA and you can probably get an idea of what you need to export & its calling conventions. That said I'm sure the compression dll's are documented somewhere, as I believe more programs utilize them.