Android: Resizing Bitmaps Without Losing Quality
Answer : Good downscaling algorithm (not nearest neighbor like) consists of just 2 steps (plus calculation of the exact Rect for input/output images crop): downscale using BitmapFactory.Options::inSampleSize->BitmapFactory.decodeResource() as close as possible to the resolution that you need but not less than it get to the exact resolution by downscaling a little bit using Canvas::drawBitmap() Here is detailed explanation how SonyMobile resolved this task: http://developer.sonymobile.com/2011/06/27/how-to-scale-images-for-your-android-application/ Here is the source code of SonyMobile scale utils: http://developer.sonymobile.com/downloads/code-example-module/image-scaling-code-example-for-android/ Try below mentioned code for resizing bitmap. public Bitmap get_Resized_Bitmap(Bitmap bmp, int newHeight, int newWidth) { int width = bmp.getWidth(); int height = bmp.getHeight(); float scaleWidth = ((float) newWidth) / width; float scaleH...