Searched refs:goldenImage (Results 1 – 1 of 1) sorted by relevance
/platform_testing/libraries/screenshot/deviceless/layoutlib/tests/src/com/android/layoutlib/bridge/intensive/util/ |
D | ImageUtils.java | 70 BufferedImage goldenImage = ImageIO.read(is); in requireSimilar() local 71 assertImageSimilar(relativePath, goldenImage, image, MAX_PERCENT_DIFFERENCE); in requireSimilar() 78 public static void assertImageSimilar(String relativePath, BufferedImage goldenImage, in assertImageSimilar() argument 80 if (goldenImage.getType() != TYPE_INT_ARGB) { in assertImageSimilar() 81 BufferedImage temp = new BufferedImage(goldenImage.getWidth(), goldenImage.getHeight(), in assertImageSimilar() 83 temp.getGraphics().drawImage(goldenImage, 0, 0, null); in assertImageSimilar() 84 goldenImage = temp; in assertImageSimilar() 86 assertEquals(TYPE_INT_ARGB, goldenImage.getType()); in assertImageSimilar() 88 int imageWidth = Math.min(goldenImage.getWidth(), image.getWidth()); in assertImageSimilar() 89 int imageHeight = Math.min(goldenImage.getHeight(), image.getHeight()); in assertImageSimilar() [all …]
|