When rotating scanned JPEGs, the fielsize decreases significantly. For example, I have an image who's size attributes are (3493x2319x24) before rotation has a size of 4.32MB. If I rotate it using the Convert dialog, the attributes are (2319x3493x24) and the size is 4.57MB, which I consider to be reasonable. If I then try rotating it again, but using the following command on a button:
Image ROTATE=90 HERE REPLACE
@nodeselect
The attributes are then (3493x2319x24) and the size is then 610KB. I have tried using the NOLOSSLESS argument both as Yes & NO, but the same behavior is displayed. While the image still looks ok, I am concerned about the apparent loss in size.
No all JPEGs can be rotated losslessly. It’s likely being recompressed.
I appreciate that. But that doesn't explain why when I use the Convert Images dialog, the file size is very similar, and even larger at times. I also would have expected such a dramatic difference in file size.
JPEG compression can result in big size differences depending on the quality selected.
For a more definitive answer, we need a zipped copy of the file in question and instructions on exactly what to do to it to see the same result.
Leo, thanks for the follow up. I have attached a copy of a file that exhibits the behavior.
Image Focus Test #3.zip (4.3 MB)
If I then use the Image Conversion tool as follows, I get the file correctly rotated, with a file size of 4.42 MB:
If I use the Rotate Right button on the image toolbar, I get a rotated file with a file size of 621 KB:
Lossless JPEG rotation requires the image width/height to be a multiple of 8 pixels, which your original dimensions would not meet.
Ok, I wasn't aware of that. It still doesn't explain why it seems to work with the Image Conversion Tool, but not the command on a button.
You have the tool set to 100% quality; the command isn't explicitly setting the quality, so it will default to something less than 100%.
Thanks for the update Jon. How do i force the 100% quality with the command?
Add QUALITY=100
to the command line.
Jon, thanks very much for your help. That resolved the issue