Results 1 to 3 of 3

Thread: Bitonal image compression and interlacing

  1. #1
    Member Karhunen's Avatar
    Join Date
    Dec 2011
    Location
    USA
    Posts
    91
    Thanks
    2
    Thanked 1 Time in 1 Post

    Bitonal image compression and interlacing

    Here is the discussion on why raster images should be interlaced for a slow connection: http://en.wikipedia.org/wiki/Interlacing_(bitmaps)

    But I have had the experience that interlacing an image, either under LZW with GIF or Deflate with PNG seems to improve the compression.

    I have attached a zip file of the files I was working with, apparently from wikimedia based on the filenames:

    My question is, is the benefit from compression because interlacing "exposes" the self-similarity of the image, or is it because the interlacing imposes a sorting of the image elements that is easier to compress ?

    I think it is the latter because this seems to work with a lot of line-art images that are drawn by a human. Anybody have an interesting test set of 1bpp images ?
    Attached Thumbnails Attached Thumbnails Click image for larger version. 

Name:	segment.png 
Views:	226 
Size:	9.9 KB 
ID:	2073  
    Attached Files Attached Files
    Last edited by Karhunen; 5th November 2012 at 20:27. Reason: Board converted 4000x4000x1 png to Jpeg 1100x1100

  2. #2
    Member
    Join Date
    Jun 2009
    Location
    Kraków, Poland
    Posts
    1,494
    Thanks
    26
    Thanked 131 Times in 101 Posts
    Well, from counting theorem we have that if one algorithm compresses some files better than other algorithm, then it has to compress some files worse. So if interlacing usually worsens compression ration, then it should improve compression in rare cases.

    I think, if you separate odd and even lines from the image to two separate images, then one will have a lot of white pixels and one will have a lot of black pixels. That would be a reson for improved compression.

  3. #3
    Expert
    Matt Mahoney's Avatar
    Join Date
    May 2008
    Location
    Melbourne, Florida, USA
    Posts
    3,257
    Thanks
    307
    Thanked 795 Times in 488 Posts
    Right. I think interlacing would make compression worse for most images. In the maze image, the even and odd lines have obviously different statistics.

Similar Threads

  1. WebP (lossy image compression)
    By Arkanosis in forum Data Compression
    Replies: 62
    Last Post: 12th April 2019, 18:45
  2. UCI Image Compression
    By maadjordan in forum Data Compression
    Replies: 5
    Last Post: 19th August 2017, 23:15
  3. BCIF image compression program
    By m^2 in forum Data Compression
    Replies: 35
    Last Post: 26th April 2013, 16:02
  4. 3d image compression
    By m^2 in forum Data Compression
    Replies: 5
    Last Post: 9th July 2012, 08:52
  5. Quo Vadis JPEG - New Movements in Still Image Compression
    By thorfdbg in forum Data Compression
    Replies: 37
    Last Post: 14th June 2012, 20:47

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •