Can a JPEG compressed image be rotated without a loss in quality?

后端 未结 10 1566
灰色年华
灰色年华 2020-12-14 01:45

JPEG is a lossy compression scheme, so decompression-manipulation-recompression normally reduces the image quality further for each step. Is it possible to rotate a

10条回答
  •  半阙折子戏
    2020-12-14 01:56

    Absolutely - just change the orientation value in the EXIF data. The vast majority of image programs will respect this setting and show the picture "rotated".

    It's also possibly to "manually" (e.g. programatically) rotate the image in a lossless fashion if certain criteria are true - rotation must be 90/180 degrees and the width/height must multiples of the block-size. You can also flip/mirror it. I don't know whether image programs are smart enough to special-case this operation though. I would guess not.

提交回复
热议问题