                             LZHUF_1.DLL - v2.0
                             ==================
                                 (27-04-96)

                   LZHUF compression by Haruyasu Yoshizaki
                        Adapted by Jean-Paul ROUBELAT
            DLL'ed by Charlie McIver - Purple Computer Solutions
                  
              Unrestricted use -=- Source available on request

The LZHUF_1 DLL is simply a 16 bit Windows DLL implementation of the 
LZHUF_1.EXE program, as modified by Jean-Paul Roubelat for use within his
F6FBB server system. 

This DLL expects only message text to be stored in a file. So, when compressing
the source file should only contain the message text. Similiarly when expanding
you should dump all the data that FBB sends you in a file, and call the 
decoding function. The output file contains only message text.

The format of a compressed file is :-

byte      description
======================================
0,1     - CRC16
2,3,4,5 - Length of uncompressed file
6 ->    - Rest of file

Here are the function definitions :-

int FAR PASCAL _export lz_decode(int mode, LPSTR infilename, LPSTR outfilename)
int FAR PASCAL _export lz_encode(int mode, LPSTR infilename, LPSTR outfilename)

Visual Basic declarations :-

Declare Function lz_decode Lib "LZHUF_1.DLL" ( ByVal mode As Integer, ByVal infilename As String, ByVal outfilename As String) As Integer
Declare Function lz_encode Lib "LZHUF_1.DLL" ( ByVal mode As Integer, ByVal infilename As String, ByVal outfilename As String) As Integer

lz_encode is the encoder (i.e. it compresses)
lz_decode is the decoder (i.e. it re-expands)

mode        - Version one compression (utilises CRC16) (0 or 1)
infilename  - Name of input file
outfilename - Name of output

Both functions return an integer, a non zero means a problem was encountered.

Users should be aware that I have added nothing to the encoding/decoding
so if you tell the DLL something wrong it can have an abstract outcome!
If you ever played with the original version, and you tried to decompress a
version 1 file with version 0 compression, it sat in a loop eating up harddisk
space. This can still happen, you have been warned!

I have started a list of people developing software using this DLL. If you
wish to be added to this then simply ask. This way I can tell people when I
update it.

This was a very simple and basic conversion, additions are possible, just ask!

I don't think there are any bugs, but it isn't impossible!

Supplied in the zip are the original source and docs supplied to me by Jean
Paul Roubelat (F6FBB) contained within another ZIP LZHUF_1.ZIP.

As of 09/04/96 the zip is distributed as LZHUFxx.ZIP where xx is a release
number.

Purple Computer Solutions
31 Hartshill
Bedford
MK41 9AL
UK

Tel : +44 (0)1234 328816
Fax : +44 (0)1234 328817

Email: CharlieM@b-m-s.demon.co.uk
       CharlieM@thresh.demon.co.uk

AX25 : G7MYO @ GB7BED.#21.GBR.EU

I would prefer if people contact me by post or by email / AX25. This is 
cheaper and I can answer at my leisure!


Revision History :-

Date      Rel  Comments
================================================================
02-02-96  1.0  First version done
27-04-96  2.0  New version, with static libraries not DLL's