Home
last modified time | relevance | path

Searched refs:aspRatio (Results 1 – 2 of 2) sorted by relevance

/frameworks/base/core/tests/coretests/src/android/graphics/drawable/
DIconTest.java455 float aspRatio = (float) origWidth / (float) origHeight; in getMaxWidth() local
456 int newHeight = (int) Math.sqrt(maxNumPixels / aspRatio); in getMaxWidth()
457 return (int) (newHeight * aspRatio); in getMaxWidth()
461 float aspRatio = (float) origWidth / (float) origHeight; in getMaxHeight() local
462 return (int) Math.sqrt(maxNumPixels / aspRatio); in getMaxHeight()
/frameworks/base/graphics/java/android/graphics/drawable/
DIcon.java415 float aspRatio = (float) bitmap.getWidth() / (float) bitmap.getHeight(); in fixMaxBitmapSize() local
416 int newHeight = (int) Math.sqrt(maxNumPixels / aspRatio); in fixMaxBitmapSize()
417 int newWidth = (int) (newHeight * aspRatio); in fixMaxBitmapSize()