J2ME Reduce Image color-depth/ Compress Image size

Posted by updateraj on Stack Overflow See other posts from Stack Overflow or by updateraj
Published on 2009-01-09T00:22:12Z Indexed on 2010/06/12 5:42 UTC
Read the original article Hit count: 330

Filed under:
|
|
|
|

Hi,

I need to transmit the image from the mobile phone to the server. I am able to reduce the image screen size but not the memory size. I understand i have to deal with the color depth. J2ME does not seem to offer any scaling method which is available in J2SE:

image rescaled = image.getScaledInstance(thumbWidth, thumbHeight,  Image.SCALE_AREA_AVERAGING);
BufferedImage biRescaled = toBufferedImage(rescaled, thumbWidth, thumbHeight, BufferedImage.TYPE_INT_RGB);

How i would i tackle this ? I would like to reduce the image memory size before i transmit to the server. Thank you

© Stack Overflow or respective owner

Related posts about image

Related posts about java-me