Results 1 to 6 of 6

Thread: I need help with precomp

  1. #1
    Member
    Join Date
    Sep 2011
    Location
    andora
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Lightbulb I need help with precomp

    Hi guys



    i want to gain more compression in a zip file, "fonts.zip" --> 3,59 MB, uncompressed obtain a folder called fonts --> 50 MB

    I've tried to preprocess the file "fonts.zip" using precomp (precomp -c- -slow) but the results is about a 3,5 MB *.pcf file.

    would not have to be 50 MB, what they weighed the folder "fonts"?

    that's what I do wrong?

    Anyone has a suggestion?
    Thanks!

    i have attached the file
    fonts.zip

    sorry for my bad english.

  2. #2
    Programmer schnaader's Avatar
    Join Date
    May 2008
    Location
    Hessen, Germany
    Posts
    539
    Thanks
    192
    Thanked 174 Times in 81 Posts
    Not all zLib streams can be recompressed successfully by Precomp, this file is a good example for this. Only 56 of 100 ZIP streams can be recompressed and those are only the smallest of the files. That's a limitation of Precomp at the moment that won't be solved soon.

    So you're doing nothing wrong, you just stumbled upon a file that Precomp can't handle well.
    http://schnaader.info
    Damn kids. They're all alike.

  3. #3
    Member
    Join Date
    Sep 2011
    Location
    andora
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by schnaader View Post
    Not all zLib streams can be recompressed successfully by Precomp, this file is a good example for this. Only 56 of 100 ZIP streams can be recompressed and those are only the smallest of the files. That's a limitation of Precomp at the moment that won't be solved soon.

    So you're doing nothing wrong, you just stumbled upon a file that Precomp can't handle well.
    thanks for the reply.
    but the file is compressed with the method "deflate".

    zlib should recognize the header, right?

  4. #4
    Programmer Bulat Ziganshin's Avatar
    Join Date
    Mar 2007
    Location
    Uzbekistan
    Posts
    4,497
    Thanks
    733
    Thanked 659 Times in 354 Posts
    precomp may decompress only the data compressed by zlib itself, nit by other libraries compatible with zlib

    it's due to way it does backward conversion - data are compressed back by zlib, so in order to get EXACTLY THE SAME data as in original file, the original file should be compressed by exactly the same zlib

  5. #5
    Member
    Join Date
    Sep 2011
    Location
    andora
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts
    ok

  6. #6
    Programmer schnaader's Avatar
    Join Date
    May 2008
    Location
    Hessen, Germany
    Posts
    539
    Thanks
    192
    Thanked 174 Times in 81 Posts
    For a better understanding, you can do the following: Decompress fonts.zip and compress it again using your favorite ZIP compressor. Although very simplified, this is the essence of what Precomp does. You'll get a result similar to this one:

    Code:
    fonts_original.zip 3767090 bytes
    fonts_rezip.zip    3659417 bytes
    As you can see, the recompressed ZIP file clearly isn't the same as the original, although the content is the same. Precomp has to find a way to recompress the ZIP file bit-to-bit identical because it is a lossless algorithm and as there are simply too much possibilites, it often won't be successful.
    http://schnaader.info
    Damn kids. They're all alike.

Similar Threads

  1. Precomp (and Precomp Comfort) in 315 kb
    By Yuri Grille. in forum Data Compression
    Replies: 2
    Last Post: 1st April 2009, 19:40

Posting Permissions

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