Results 1 to 9 of 9

Thread: Open source JPEG compressors

  1. #1
    Programmer
    Join Date
    May 2008
    Location
    PL
    Posts
    157
    Thanks
    4
    Thanked 13 Times in 3 Posts

    Open source JPEG compressors

    The first open source JPEG (re)compressor is PAQ (http://mattmahoney.net/dc/), but it's a little bit slow. Here is my JPEG (re)compressor which is based on uncmpJPG from JPEG Open Source Developers Package by Matthias Stirner. It's not optimized for speed and designed for files bigger than 100 kb.
    Usage:
    a) compression "rejpeg file1.jpg file2.jpg ..."
    b) decompression "rejpeg file1.rjg file2.rjg ..."
    Attached Files Attached Files

  2. #2
    Administrator Shelwien's Avatar
    Join Date
    May 2008
    Location
    Kharkov, Ukraine
    Posts
    2,061
    Thanks
    0
    Thanked 5 Times in 4 Posts
    rejpeg surprisingly supports progressive jpegs, which is really nice
    (paq and some others don't afaik)

    Now, this is the mentioned "JPEG Open Source Developers Package by Matthias Stirner":
    http://www.elektronik.htw-aalen.de/p...ge%20v1.0d.zip

    Also some other decoders:
    http://nishi.dreamhosters.com/u/decoders_0.rar

    And this is my refactored version of jpeg decoder from jpeglib v7:
    http://nishi.dreamhosters.com/u/djpeg_vA.rar
    (supports arithmetic jpegs)

    Now here's pjpg source:
    http://nishi.dreamhosters.com/u/pjpg_v0.rar
    Although its buggy, doesn't support progressive mode, and has worse ratio than rejpeg.
    But at least its faster :)

  3. #3
    Programmer schnaader's Avatar
    Join Date
    May 2008
    Location
    Hessen, Germany
    Posts
    342
    Thanks
    1
    Thanked 1 Time in 1 Post
    Good work. Quick test:

    Code:
    Original: 15 files, 10.064.531 bytes
    pjpg_v0: 8.381.297 bytes, 34 s
    packjpg 2.4: 7.939.727 bytes, 63 s
    rejpeg 0.1: 7.987.513 bytes, 74 s
    By the way, you might have a look at the attached (corrupt) JPG file. It leads to a crash both in PackJPG and rejpeg.
    Attached Files Attached Files
    http://schnaader.info
    Damn kids. They're all alike.

  4. #4
    Member m^2's Avatar
    Join Date
    Sep 2008
    Location
    Ślůnsk, PL
    Posts
    1,420
    Thanks
    6
    Thanked 26 Times in 20 Posts
    Sizes:
     File1File2File3File4File5File6File7Average savings(%)
    Original74191831619579613621545276223232316908871001200
    rejpeg63653521411105543139495169201736212320868583414,11
    PackJPG63221831393636533797492375202267912478308149915,09
    pjpg7405639161308361203954418020997531678005995011,19
    Times
     File1File2File3File4File5File6File7
    Original7419183161957961362154527622323231690887100120
    rejpeg12.2503.0781.1560.8753.0004.3120.281
    PackJPG16.6253.6711.3901.1094.2034.4530.250
    pjpg3.9531.0150.3430.3123.0311.0310.125
    PAQ8 hung at 99.98% of file1 and 99.90% on file2 with 0% CPU usage, I killed it after some time and didn't try further.
    PackJPG 2.4
    rejpg 0.1
    pjpg_v0
    PAQ8px_v69

  5. #5
    Administrator Shelwien's Avatar
    Join Date
    May 2008
    Location
    Kharkov, Ukraine
    Posts
    2,061
    Thanks
    0
    Thanked 5 Times in 4 Posts
    These are probably "progressive" jpegs (except for File5). pjpg and paq8 can't parse these.
    You can generate some more files like that with arithmetic coding or new jpeglib8 features -
    then even rejpeg/packjpg would fail.

  6. #6
    Member m^2's Avatar
    Join Date
    Sep 2008
    Location
    Ślůnsk, PL
    Posts
    1,420
    Thanks
    6
    Thanked 26 Times in 20 Posts
    Possibly. But I wanted to have something representative for my workload and that's it.
    How can I check if they are progressive?

    EDIT: Imagine can show such info, yes except for 5 they are progressive.
    Last edited by m^2; 12th March 2011 at 13:16.

  7. #7
    Member
    Join Date
    May 2008
    Location
    England
    Posts
    309
    Thanks
    0
    Thanked 0 Times in 0 Posts
    This will show you all the internal info of JPEGs and if there are any errors.

    http://www.impulseadventure.com/photo/jpeg-snoop.html

  8. #8
    Member Vacon's Avatar
    Join Date
    May 2008
    Location
    Germany
    Posts
    523
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Hello everyone,

    not bad for a 0.1!
    But to be honest, I was not prepared to find rejpeg saying:
    Code:
    --> reJPEG v0.1 (1/06/2010) - JPEG file compressor by Przemyslaw Skibinski (base
    d on work of Matthias Stirner) <--
    
    rejpeg file.jpg -> Expanding... -> 76,5 %
    respective viceversa:
    Code:
    --> reJPEG v0.1 (1/06/2010) - JPEG file compressor by Przemyslaw Skibinski (base
    d on work of Matthias Stirner) <--
    
    
    rejpeg file.rjg" -> Compressing -> 79.84%
    [...]
    Best regards!
    Last edited by Vacon; 12th March 2011 at 17:10.

  9. #9
    Member packDEV's Avatar
    Join Date
    Oct 2011
    Location
    Germany
    Posts
    37
    Thanks
    10
    Thanked 42 Times in 9 Posts
    Late reply . I already fixed the bug in the latest non public packJPG version and I'll fix it in my Open Source Developers Package, too, within the next few days.

Similar Threads

  1. PeaZip - open source archiver
    By squxe in forum Data Compression
    Replies: 1
    Last Post: 3rd December 2009, 23:01
  2. BALZ - An Open-Source ROLZ-based compressor
    By encode in forum Data Compression
    Replies: 57
    Last Post: 3rd August 2008, 02:44
  3. fcm1 - open source order-1 cm encoder
    By encode in forum Data Compression
    Replies: 34
    Last Post: 5th June 2008, 00:16
  4. New fast open-source paq-based jpeg compressor
    By Bulat Ziganshin in forum Forum Archive
    Replies: 14
    Last Post: 13th September 2007, 14:57
  5. Replies: 0
    Last Post: 26th July 2007, 19: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
  •