Code example for ExifInterface

Methods: getAttribute

0
                    // 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);
                if ((orientation != null) && (orientation.equals("90") || orientation.equals("180") || orientation.equals("270"))) {