[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[libredwg] LZ77 Compression

From: Dave Coventry
Subject: [libredwg] LZ77 Compression
Date: Wed, 12 Sep 2012 20:17:15 +0200

Can someone assist me on decoding LZ77 compression?

I am trying to read a 2007 dwg file.

I have extracted the header information at address 0x80 and have
selected every third byte which I have stored in a data array.

The array has the following information beginning at byte 32:


Reading the sourcecode decode_r2007.c:

unsigned char opcode = *src++;

  if ((opcode & 0xf0) == 0x20)
      src += 2;
      length = *src++ & 0x07;

      if (length == 0)
        return 1;

opcode is indeed 0x20, and length is 2.

But where to next? I suppose I'm a little confused by the pointer
programming, and I can't work out the process.

Thank you,

Dave Coventry

reply via email to

[Prev in Thread] Current Thread [Next in Thread]