Paszlib Handling zlib with Pascal.

Zaehler  What Is Paszlib ?

Paszlib is a port of the zlib data compression library to Pascal. The original C source was written and is maintained by Jean-Loup Gailly and Mark Adler. The current Pascal release is based on zlib 1.1.2.
It was tested under DOS real mode with Turbo Pascal 7.0 for DOS (TP7), under Borland Pascal 7 DPMI and under Win32 with Delphi 3.02.

April 7th, 2000

  • Fixed minizip translation error and DPMI conditional defines
March 2000
  • Code update with minor changes, translation of the minizip packages.
Oktober 1999
  • I recommend to change the declaration of the field "z_stream.msg" in zlib.pas, line 280, from "string" to "string[255]" (ShortString) to avoid problems with Delphi 2+ dynamic string handling.
May 7th, 1999
  • Some changes for Free Pascal Compiler compatibility. deflateCopy() has new parameters trees.pas - record constant definition
June 25th, 1998
  • translation bug (memory leak) fixed: in inftrees.pas, inflate_trees_dynamic(), "ZFREE(z, v);" was missing in line 574. Thanks to Thomas Blohorn and Fabrice Doriot.
June 17th, 1998
  • 1.1.2 patch - official patch for a rare inflate buffer bug applied.
  • demo "example.pas" now compile as is: Memcheck turned off by default.
  • Delphi 1 - memory allocation fixed.
  • Stream classes - dzlib.txt file added.
  • compress2() is now exported

Links

How to?

  • outline for file decompression: Sample 1
  • Use the compression code under real mode DOS: lower the memory requirements by lowering MAX_WBITS and MAX_MEM_LEVEL.
  • If you are using Delphi 5, {$define Delphi5} in zconf.inc will silence some warnings. You might also change the NMAX constant in "adler.pas"
    const
      NMAX = 5552; { from 3854 }
    
    This works because the "Cardinal" type is 32 bits there and not 31 bits like in earlier Delphi releases.

Who, Me ?

Nomssi is my name, Nomssi Nzali Jacques H. C. I'm cameroonian physicist studying in Chemnitz, Germany, a long time Turbo Pascal user and a graphics freak. Check out my home page, my Graphics file viewer for SuperVGA, my Pascal port of the IJG library and send hate mail, fan mail and marriage proposals to nomssi@physik.tu-chemnitz.de


Copyright © 1998,1999, 2000 by Jacques Nomssi Nzali
This page last updated on May 5th, 2000