summaryrefslogtreecommitdiffstats
path: root/src/com/android/camera/data/LocalMediaData.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/com/android/camera/data/LocalMediaData.java')
-rw-r--r--src/com/android/camera/data/LocalMediaData.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/com/android/camera/data/LocalMediaData.java b/src/com/android/camera/data/LocalMediaData.java
index 071a9ca52..fef141f55 100644
--- a/src/com/android/camera/data/LocalMediaData.java
+++ b/src/com/android/camera/data/LocalMediaData.java
@@ -472,7 +472,7 @@ public abstract class LocalMediaData implements LocalData {
if (mWidth > mDecodeWidth || mHeight > mDecodeHeight) {
int heightRatio = Math.round((float) mHeight / (float) mDecodeHeight);
int widthRatio = Math.round((float) mWidth / (float) mDecodeWidth);
- sampleSize = heightRatio < widthRatio ? heightRatio : widthRatio;
+ sampleSize = Math.max(heightRatio, widthRatio);
}
BitmapFactory.Options opts = new BitmapFactory.Options();