Why does making something smaller, make it bigger ?

I was tinkering with a 1.5Mb JPEG, cropping a bit off it, by about 25%.

But when I came to save the new file, instead of it being a bit smaller, it had increased in size by 1Mb !

I'd never seen that before !

What gives ?

  • 9
    Different compression vs. quality tradeoff setting.
  • 4
    Jpeg has a quality setting. Higher quality means more iterations when it approximates the original image, and that means more data.

    Most image editors will let you change the quality seeing before saving.
  • 3
    because you need space for rootkits too
  • 1

    Yeah, but you can't make more quality from a compressed image can you !
  • 0

    I'll have to experiment a bit to better understand it.

    Another item tacked onto the todo list..
  • 1

    > you can't make more quality from a compressed image can you !

    That's correct. But once you decompress the image to display or edit it, programs are completely unaware that it was compressed before, it's just a bunch of uncompressed pixels again. Saving it as JPEG will degrade quality due to compression again - you can't "reuse" old compression.

    Every now and then you can see terribly compressed memes on various social media sites. It's not because the quality setting is low. It's because every time someone saves the image and uploads to another site, it gets compressed again and again and again, each time adding new quality losses.
Add Comment