home *** CD-ROM | disk | FTP | other *** search
- Using Squish in your own programs
- ---------------------------------
-
- The Module
-
- This program is intended to compress and decompress files in programs which
- will require compression, the code has been written as a module so that all
- the machine code can be used simply and efficiently in other programs. The
- module can be taken straight out of the Application (Use Shift and double-
- click on the Squish icon, and copy the file called "SquishMod") and then used
- in any other program. The code is accessed by the use of Software Interupt
- calls ("SWI", or in BASIC "SYS") these are designed to be simple and easy to
- use. The module can be used on the conditions:
- * It is not altered in any way without my written permission.
- * The program acknowledges the authors of the module
- (Dave Lodge & Ian Jeffray)
- * We recieve a copy of the program.
-
-
- SWI Calls
- ---------
-
- There are several SWI calls in the module, these are mentioned below:
-
- Squish_Compact
-
- This compacts the required data.
-
- On Entry R0 = Method (see Below)
- R1 = Address to compact to
- R2 = Address to compact from
- R3 = Size of Input File + R1
-
- On Exit R0 = Size of Output File + R2
-
- Example SYS "Squish_Compact",1,to,from,isize TO osize
-
-
-
- Squish_Decompact
-
- This decompacts the required data.
-
- On Entry As Above
-
- On Exit As Above
-
-
-
- Squish_Version
-
- This returns the address of the version string in R0
-
- On Entry -
-
- On Exit R0 = Address of Version String
-
- Example SYS "Squish_Version" TO A
- PRINT $A
-
-
-
- Squish_FillIcon
-
- This fills an icon in a window with the given string
-
- On Entry R0 = Window handle
- R1 = Icon to be filled
- R2 = Address of string to be placed in icon
-
- On Exit -
-
- Example SYS "Squish_FillIcon",Info,6,Version$
-
-
- Methods
- -------
-
- The Methods are:
- Number Method
-
- Byte and Counter 1
- Counter and Byte 2
- Byte and Counter Mod. 3
- Counter and Byte Mod. 4
- LZW (nsy) 5
- Huffman Encoding (nsy) 6
-
- * nsy : Not Supported Yet
-
-
-