Code example for ExifInterface

Methods: getAttribute

                    // out of memory 
                    return null; 
                if (bm == null)
                    return null; 
                float percentage = (float) finalWidth / bm.getWidth();
                float proportionateHeight = bm.getHeight() * percentage;
                finalHeight = (int) Math.rint(proportionateHeight);
                float scaleWidth = ((float) finalWidth) / bm.getWidth();
                float scaleHeight = ((float) finalHeight) / bm.getHeight();
                float scaleBy = Math.min(scaleWidth, scaleHeight);
                // Create a matrix for the manipulation 
                Matrix matrix = new Matrix();
                // Resize the bitmap 
                matrix.postScale(scaleBy, scaleBy);
Connect your IDE to all the code out there  Get Codota for Java