I have a JPEG from my camera that is 3264x1952. This file is about 1.7 megabytes.
I'm wondering is there anyway to compress this image to a smaller file size without changing the resolution. i.e. I want my resultant image to also be 3264x1952.
I cannot even open this JPEG as a bitmap without using the inSampleSize option to scale down the image.
Anyone know what my options are? Is there any way to reduce color bit depth/increase compression/reduce quality?
edit: I'm specifically looking for a solution for Android. Main problem being I can't open the full res JPEG without hitting a OOM error, so I don't know how to proceed.
Ideally I'd like to do:
bitmap.compress(Bitmap.CompressFormat.JPEG, 50, out);
But the application will crash when I do:
Bitmap bitmap = BitmapFactory.decodeFile(imgFile.getAbsolutePath());