Programmatically Reducing JPEG file size

Viewed 12850

Apologies for any ignorance, but I have never worked with jpeg images (let alone any types of images) in Java before.

Supposing I want to send a jpeg image from a web service to a client. Is there any way that I can reduce the jpeg file size by manipulating the colour profile of the image in some way?

I have already been able to reduce the image size by scaling it using a neat tool for BufferedImages called imgscalr. See here.

I would also like a jpeg that has less colours than a high quality jpeg image. For example, I would like to be able to use 8bit colour in my jpeg instead of say 16bit colour.

What exactly would I need to change if I have a BufferedImage from Java's 2D package?

4 Answers
Related