Closed GoogleCodeExporter closed 8 years ago
Thank you for filing this issue.
The `outputQuality` method is used to specify the output quality of the
*compression algorithm when writing to a file or output stream*.
Therefore, using `outputQuality` when the output is a `BufferedImage` does not
affect the final output.
I have clarified this behavior in the documentation for the `outputFormat` and
`outputQuality` methods.
-> It should be noted that the `BufferedImage` object does not have a property
to mark what output quality should be used when it is written to an image. As a
result, the output quality will not change.
In order for `outputQuality` to actually change the compression quality of the
final thumbnail, one must use one of the methods that outputs to a `File` or
`OutputStream`.
For example:
Thumbnails.of("path/to/image.jpg")
.size(100, 100)
.outputQuality(0.8)
.toFile("path/to/thumbnail.jpg");
The above code will set the JPEG output quality to 0.8 when writing the JPEG
image.
Original comment by coobird...@gmail.com
on 3 Sep 2013 at 4:13
Original issue reported on code.google.com by
marek.kr...@fullsix.com
on 27 Aug 2013 at 12:49