Home
last modified time | relevance | path

Searched refs:bitmap2 (Results 1 – 14 of 14) sorted by relevance

/cts/tests/app/WallpaperTest/src/android/app/cts/wallpapers/util/
DWallpaperTestUtils.java63 public static boolean isSimilar(Bitmap bitmap1, Bitmap bitmap2, boolean requireSameDimensions) { in isSimilar() argument
64 if (bitmap1 == null || bitmap2 == null) return bitmap1 == null && bitmap2 == null; in isSimilar()
67 if (width != bitmap2.getWidth() || height != bitmap2.getHeight()) { in isSimilar()
69 Bitmap largest = width >= bitmap2.getWidth() ? bitmap1 : bitmap2; in isSimilar()
70 Bitmap smallest = largest == bitmap1 ? bitmap2 : bitmap1; in isSimilar()
90 int pixel2 = bitmap2.getPixel(x, y); in isSimilar()
/cts/tests/tests/renderscript/src/android/renderscript/cts/refocus/
DImageCompare.java48 public static double psnr(Bitmap bitmap1, Bitmap bitmap2) { in psnr() argument
49 if (bitmap1.getWidth() != bitmap2.getWidth() || in psnr()
50 bitmap1.getHeight() != bitmap2.getHeight()) { in psnr()
54 if (bitmap1.sameAs(bitmap2)) { in psnr()
68 int pixel2 = bitmap2.getPixel(x, y); in psnr()
/cts/tests/tests/uirendering/src/android/uirendering/cts/util/
DBitmapAsserter.java31 public static void assertBitmapsAreSimilar(Bitmap bitmap1, Bitmap bitmap2, in assertBitmapsAreSimilar() argument
37 if (width != bitmap2.getWidth() || height != bitmap2.getHeight()) { in assertBitmapsAreSimilar()
44 bitmap2.getPixels(pixels2, 0, width, 0, 0, width, height); in assertBitmapsAreSimilar()
48 BitmapDumper.dumpBitmaps(bitmap1, bitmap2, new PassFailVisualizer()); in assertBitmapsAreSimilar()
/cts/tests/tests/uirendering27/src/android/uirendering/cts/util/
DBitmapAsserter.java49 public void assertBitmapsAreSimilar(Bitmap bitmap1, Bitmap bitmap2, BitmapComparer comparer, in assertBitmapsAreSimilar() argument
55 if (width != bitmap2.getWidth() || height != bitmap2.getHeight()) { in assertBitmapsAreSimilar()
62 bitmap2.getPixels(pixels2, 0, width, 0, 0, width, height); in assertBitmapsAreSimilar()
66 BitmapDumper.dumpBitmaps(bitmap1, bitmap2, testName, mClassName, mDifferenceVisualizer); in assertBitmapsAreSimilar()
/cts/tests/quickaccesswallet/src/android/quickaccesswallet/cts/
DTestUtils.java42 Bitmap bitmap2 = ((BitmapDrawable) drawable2).getBitmap(); in compareIcons() local
43 assertThat(BitmapUtils.compareBitmaps(bitmap1, bitmap2)).isTrue(); in compareIcons()
/cts/tests/tests/graphics/src/android/graphics/cts/
DBitmapTest.java1983 Bitmap bitmap2 = Bitmap.createBitmap(100, 100, Config.ARGB_8888); in testSameAs_simpleSuccess() local
1985 bitmap2.eraseColor(Color.BLACK); in testSameAs_simpleSuccess()
1986 assertTrue(bitmap1.sameAs(bitmap2)); in testSameAs_simpleSuccess()
1987 assertTrue(bitmap2.sameAs(bitmap1)); in testSameAs_simpleSuccess()
1993 Bitmap bitmap2 = Bitmap.createBitmap(100, 100, Config.ARGB_8888); in testSameAs_simpleFail() local
1995 bitmap2.eraseColor(Color.BLACK); in testSameAs_simpleFail()
1996 bitmap2.setPixel(20, 10, Color.WHITE); in testSameAs_simpleFail()
1997 assertFalse(bitmap1.sameAs(bitmap2)); in testSameAs_simpleFail()
1998 assertFalse(bitmap2.sameAs(bitmap1)); in testSameAs_simpleFail()
2004 Bitmap bitmap2 = Bitmap.createBitmap(150, 150, Config.ARGB_8888); in testSameAs_reconfigure() local
[all …]
DBitmapColorSpaceTest.java370 Bitmap bitmap2 = BitmapFactory.decodeStream(in, null, opts); in reuse() local
371 assertSame(bitmap1, bitmap2); in reuse()
372 ColorSpace cs = bitmap2.getColorSpace(); in reuse()
/cts/tests/accessibilityservice/src/android/accessibilityservice/cts/
DAccessibilityFocusAndInputFocusSyncTest.java387 private boolean isBitmapDifferent(Bitmap bitmap1, Bitmap bitmap2) { in isBitmapDifferent() argument
398 final Bitmap bitmapTwo = bitmap2.copy(Bitmap.Config.ARGB_8888, false); in isBitmapDifferent()
410 saveFailureScreenshot(bitmap1, bitmap2); in isBitmapDifferent()
414 private void saveFailureScreenshot(Bitmap bitmap1, Bitmap bitmap2) { in saveFailureScreenshot() argument
424 BitmapUtils.saveBitmap(bitmap2, directoryName, fileName2); in saveFailureScreenshot()
/cts/tests/tests/transition/src/android/transition/cts/
DFadeTest.java255 private static double[] getMeans(Bitmap bitmap1, Bitmap bitmap2, int xStart, int yStart) { in getMeans() argument
261 avg1 += getIntensity(bitmap2.getPixel(xStart + x, yStart + y)); in getMeans()
274 private static double[] getVariances(Bitmap bitmap1, Bitmap bitmap2, double mean0, double mean1, in getVariances() argument
282 double v1 = getIntensity(bitmap2.getPixel(xStart + x, yStart + y)) - mean1; in getVariances()
/cts/tests/tests/media/decoder/src/android/media/decoder/cts/
DDecodeAccuracyTestBase.java1797 private static Difference computeDifference(Bitmap bitmap1, Bitmap bitmap2) { in computeDifference() argument
1798 return computeDifference(bitmap1, bitmap2, 0); in computeDifference()
1815 private static Difference computeDifference(Bitmap bitmap1, Bitmap bitmap2, int ignorePixels) { in computeDifference() argument
1817 if (bitmap1 == null || bitmap2 == null) { in computeDifference()
1820 if (bitmap1.equals(bitmap2) || bitmap1.sameAs(bitmap2)) { in computeDifference()
1823 … if (bitmap1.getHeight() != bitmap2.getHeight() || bitmap1.getWidth() != bitmap2.getWidth()) { in computeDifference()
1829 final double[][] pixels2 = convertRgbToCieLab(bitmap2); in computeDifference()
2068 Bitmap bitmap1, Bitmap bitmap2, int ignorePixels, Pair<Double, Double>[] borderCrops) { in computeMinimumDifference() argument
2071 Difference minDiff = computeDifference(bitmap1, bitmap2, ignorePixels); in computeMinimumDifference()
2076 Bitmap bitmap2s = shrinkAndScaleBilinear(bitmap2, borderCrop.first, borderCrop.second); in computeMinimumDifference()
[all …]
/cts/tests/autofillservice/src/android/autofillservice/cts/testcore/
DHelper.java1478 @Nullable Bitmap bitmap2) throws IOException { in assertBitmapsAreSame() argument
1480 assertWithMessage("2nd bitmap is null").that(bitmap2).isNotNull(); in assertBitmapsAreSame()
1481 final boolean same = bitmap1.sameAs(bitmap2); in assertBitmapsAreSame()
1493 final File dump2 = dumpBitmap(bitmap2, dir, filename + "-2.png"); in assertBitmapsAreSame()
/cts/tests/app/WallpaperTest/src/android/app/cts/wallpapers/
DWallpaperManagerTest.java976 Bitmap bitmap2 = mWallpaperManager.getBitmapAsUser(mContext.getUserId(), in peekWallpaperCaching_cachesWallpaper() local
978 assertThat(bitmap2).isNotSameInstanceAs(bitmap1); in peekWallpaperCaching_cachesWallpaper()
980 FLAG_SYSTEM)).isSameInstanceAs(bitmap2); in peekWallpaperCaching_cachesWallpaper()
/cts/tests/tests/widget/src/android/widget/cts/
DRemoteViewsTest.java859 private static float compareImages(Bitmap bitmap1, Bitmap bitmap2, String testLabel) { in compareImages() argument
860 if (bitmap1.getWidth() != bitmap2.getWidth() in compareImages()
861 || bitmap1.getHeight() != bitmap2.getHeight()) { in compareImages()
864 + " actual:[w=" + bitmap2.getWidth() + ",h=" + bitmap2.getHeight() + "]"); in compareImages()
882 int pix2 = bitmap2.getPixel(x, y); in compareImages()
/cts/tests/tests/view/src/android/view/cts/
DViewTest.java1608 Bitmap bitmap2 = view.getDrawingCache(); in testGetDrawingCache() local
1609 assertNotSame(bitmap1, bitmap2); in testGetDrawingCache()