Page 3 of 4 FirstFirst 1234 LastLast
Results 21 to 30 of 40

Thread: Mozjpeg 2.0 Improves JPEG Encoding

  1. #21
    Join Date
    May 2014
    Posts
    39

    Default

    Quote Originally Posted by quikee View Post
    This is similar as first compress with JPEG, decompress and then compress with PNG. The size of PNG will be smaller than original but not even close to that of the intermediate JPEG file. Using approaches like this will never be as efficient as a designed lossy codec.
    It is not similar. JPEG uses a Discrete Cosine Transform to decorrelate the pixels, while PNG uses pixel predictors.
    Therefore, if someone was to write a specifically lossy encoder to PNG (whyever one would do that), it would be a more efficient compression than JPEG->PNG.
    It would remain to be seen if it is more efficient than storing it as JPEG in the first place.

    Meanwhile we could start using more efficient lossy formats for cases where the lossy model is preferable, like WebP or, if - hopefully - it takes off, a Daala-based still image format.

  2. #22
    Join Date
    Jul 2013
    Posts
    386

    Default

    Quote Originally Posted by BSDude View Post
    I've had a 24" and a 27" monitors side-by-side, both 1080. I can tell you that I noticed the difference. 32" and maybe even 40" is ideal for 4k. As a comparison, for a 27" monitor with 1920x1080 resolution the pixel density amounts to 81.59 PPI (pixel per inch) while a 40" 3840x2160 resolution gives you 110.15 PPI. 32" for the same resolution would give 137.68 PPI and let's not get into 8k territory!

    I would think that even for Jumbotrons it doesn't make sense having something above 8k. But you never know, new uses could be found. They were saying 640kilobytes should be enough for everybody a while back.
    [still offtopic]
    I meant, do we even WANT 8K? It seems like it would be a complete waste of hardware/electrical power to run those displays, and your math only supports that claim. If, at 32', the resolution is 137.68PPI then I don't see a real reason to go beyond that amount of pixels (especially since, like I said, most people won't go up to 32' monitors (let alone even bigger)). Wouldn't the time it would take to make 8K a thing be better spent improving monitor tech some more? It seems like that's one of the areas that gets highly overlooked throughout computer history...
    Though, with the recent stuff like IPS, DisplayPort, and Variable Refresh Rate, things are kicking up

  3. #23
    Join Date
    Jul 2010
    Posts
    498

    Default

    Quote Originally Posted by Imroy View Post
    PNG uses deflate/LZ, not Huffman.
    And JPEG also converts RGB images into a YUV colour space, which allows for chroma sub-sampling, saving even more space.
    Look up DEFLATE Compressed Data Format Specification and try again...

  4. #24
    Join Date
    Jul 2010
    Posts
    498

    Default

    Quote Originally Posted by quikee View Post
    Do you mean JPEG LS - which is a different standard and is not supported by any JPEG decoder (it is a different format altogether) or the libjpeg 9 lossless compression mode which is a non-standard extension that will probably never be supported by anything else than libjpeg (for example libjpeg- turbo which is the most used implementation of a JPEG decoder). Also both use a different approach to lossless compression than lossy JPEG does.

    It is similar for WebP - it uses a different approach for lossy and lossless.
    Thanks for the correction, JPEG-LS and WebP don't use transformation as I've assumed.

    This is similar as first compress with JPEG, decompress and then compress with PNG. The size of PNG will be smaller than original but not even close to that of the intermediate JPEG file. Using approaches like this will never be as efficient as a designed lossy codec.
    No, I was more thinking along http://pngquant.org/

  5. #25
    Join Date
    Jan 2012
    Posts
    113

    Default

    If anyone wants one more reason, decoding JPEG files is also a lot faster than decoding PNG.

  6. #26
    Join Date
    Jan 2014
    Posts
    78

    Default

    Quote Originally Posted by DebianLinuxero View Post
    Why is so important JPEG over more modern formats like PNG?

    Why camera and video-camera brands don't use it in its products if they could save royalty's money?

    Is so bad PNG?

    Please, educate me.
    PNG is actually older format afaik and it uses data compression (delta encoding into compression) and is losless, while jpeg actually uses lossy compression.
    Jpeg works in much different manner too, first it converts RGB into Y'CbCr and then uses human eye properties to optimize from there (human eye detects changes in color shade much easier than one bright pixel in dark picture).
    Jpeg does further compress YCbCr via discrete cosine transformation and finally it uses huffman encoding to compress results of DCT into jpeg file. Decompression works in reverse.

  7. #27
    Join Date
    May 2014
    Posts
    39

    Default

    Quote Originally Posted by ssvb View Post
    If anyone wants one more reason, decoding JPEG files is also a lot faster than decoding PNG.
    Because AFAIK it is often done by the GPU (depends on the architecture of course).
    Also the bigger size of PNG naturally leads to longer decoding time ...

    I call strawman ... because raw bitmaps take absolutely no time to decode, and are thus faster ... doesn't mean they should be used everywhere ...

    Why are we even discussing this? These two format have completely different purposes. This is like discussing whether FLAC is better than MP3.

  8. #28
    Join Date
    Jan 2011
    Location
    Bathurst, NSW, Australia
    Posts
    47

    Default

    Quote Originally Posted by log0 View Post
    Look up DEFLATE Compressed Data Format Specification and try again...
    Damn, alright. But DEFLATE uses LZ77 first, before Huffman. It's not just Huffman on its own.

  9. #29

    Default

    Quote Originally Posted by Daktyl198 View Post
    [offtopic]
    As somebody who's never seen a 4k monitor, but owns a 1080p 21' monitor, is there even a reason for 8K? It seems like 4K would be perfect up to ~32', at which point the screen size is just unruly. I think most people would just go for dual-27' monitors or something.
    They where talking about 4K at 15" for laptops, which I'm all for, the cellphone market keeps getting all of these really high DPI screens, desktops and laptops have actually downgraded over the years...

    8K is for the larger screens, think 30+" in size. I'd love to get an 8K screen at 65", thats still 135.56 DPI, on a good IPS panel it'd still look good sitting in close to the screen in the living room.
    Last edited by Kivada; 07-16-2014 at 07:10 PM.

  10. #30
    Join Date
    Jul 2013
    Posts
    16

    Default

    Quote Originally Posted by CrystalGamma View Post
    It is not similar. JPEG uses a Discrete Cosine Transform to decorrelate the pixels, while PNG uses pixel predictors.
    Therefore, if someone was to write a specifically lossy encoder to PNG (whyever one would do that), it would be a more efficient compression than JPEG->PNG.
    It would remain to be seen if it is more efficient than storing it as JPEG in the first place.
    You are right - it is not the similar. What you typically do is reduce the number of colors and use dithering to compensate but this will not win (or even come close to) size/quality battle against JPEG when used at a typical color rich photo either.

    Quote Originally Posted by CrystalGamma View Post
    Meanwhile we could start using more efficient lossy formats for cases where the lossy model is preferable, like WebP or, if - hopefully - it takes off, a Daala-based still image format.
    I am all for it.. but Mozilla is still didn't integrate any of the new formats into Firefox. Daala is still far away but it would be cool if they made an image format in parallel - just to test and tune their lapped transform, intra prediction, chroma from luma and other techniques that are useful for still images.

Posting Permissions

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