Home
last modified time | relevance | path

Searched refs:getPixel (Results 1 – 25 of 76) sorted by relevance

1234

/cts/tests/tests/graphics/src/android/graphics/cts/
DLinearGradientTest.java56 assertEquals(b.getPixel(10, 10), b.getPixel(20, 10)); in testLinearGradient()
58 assertTrue(Color.blue(b.getPixel(10, 0)) > Color.blue(b.getPixel(10, 5))); in testLinearGradient()
59 assertTrue(Color.blue(b.getPixel(10, 5)) > Color.blue(b.getPixel(10, 10))); in testLinearGradient()
60 assertTrue(Color.green(b.getPixel(10, 0)) < Color.green(b.getPixel(10, 5))); in testLinearGradient()
61 assertTrue(Color.green(b.getPixel(10, 5)) < Color.green(b.getPixel(10, 10))); in testLinearGradient()
63 assertTrue(Color.green(b.getPixel(10, 15)) > Color.green(b.getPixel(10, 20))); in testLinearGradient()
64 assertTrue(Color.green(b.getPixel(10, 20)) > Color.green(b.getPixel(10, 25))); in testLinearGradient()
65 assertTrue(Color.red(b.getPixel(10, 15)) < Color.red(b.getPixel(10, 20))); in testLinearGradient()
66 assertTrue(Color.red(b.getPixel(10, 20)) < Color.red(b.getPixel(10, 25))); in testLinearGradient()
72 assertEquals(b.getPixel(10, 10), b.getPixel(20, 10)); in testLinearGradient()
[all …]
DVulkanPreTransformTest.java178 diff += pixelDiff(bitmap.getPixel(0, 0), 255, 0, 0); in validatePixelValuesAfterRotation()
179 diff += pixelDiff(bitmap.getPixel(width - 1, 0), 0, 255, 0); in validatePixelValuesAfterRotation()
180 diff += pixelDiff(bitmap.getPixel(0, height - 1), 0, 0, 255); in validatePixelValuesAfterRotation()
181 diff += pixelDiff(bitmap.getPixel(width - 1, height - 1), 255, 255, 0); in validatePixelValuesAfterRotation()
183 diff += pixelDiff(bitmap.getPixel(0, 0), 0, 255, 0); in validatePixelValuesAfterRotation()
184 diff += pixelDiff(bitmap.getPixel(width - 1, 0), 255, 255, 0); in validatePixelValuesAfterRotation()
185 diff += pixelDiff(bitmap.getPixel(0, height - 1), 255, 0, 0); in validatePixelValuesAfterRotation()
186 diff += pixelDiff(bitmap.getPixel(width - 1, height - 1), 0, 0, 255); in validatePixelValuesAfterRotation()
188 diff += pixelDiff(bitmap.getPixel(0, 0), 255, 255, 0); in validatePixelValuesAfterRotation()
189 diff += pixelDiff(bitmap.getPixel(width - 1, 0), 0, 0, 255); in validatePixelValuesAfterRotation()
[all …]
DBitmapRGBAF16Test.java114 validatePixel(0xff0f131f, mOpaqueBitmap.getPixel(0, 0)); in testGetPixel()
115 validatePixel(0xff0f1421, mOpaqueBitmap.getPixel(1, 0)); in testGetPixel()
116 validatePixel(0xff101523, mOpaqueBitmap.getPixel(2, 0)); in testGetPixel()
119 assertEquals(0xffff0000, mTransparentBitmap.getPixel(0, 0)); in testGetPixel()
120 assertEquals(0xff00ff00, mTransparentBitmap.getPixel(1, 0)); in testGetPixel()
121 assertEquals(0xff0000ff, mTransparentBitmap.getPixel(2, 0)); in testGetPixel()
124 assertEquals(0x7fff0000, mTransparentBitmap.getPixel(61, 63)); in testGetPixel()
125 assertEquals(0x7f00ff00, mTransparentBitmap.getPixel(62, 63)); in testGetPixel()
126 assertEquals(0x7f0000ff, mTransparentBitmap.getPixel(63, 63)); in testGetPixel()
131 int before = mOpaqueBitmap.getPixel(5, 5); in testSetPixel()
[all …]
DPorterDuffXfermodeTest.java54 assertEquals(Color.RED, target.getPixel(WIDTH / 4, HEIGHT / 4)); in testPorterDuffXfermode()
55 assertEquals(Color.BLUE, target.getPixel(WIDTH / 4, HEIGHT * 3 / 4)); in testPorterDuffXfermode()
56 assertEquals(Color.BLUE, target.getPixel(WIDTH * 3 / 4, HEIGHT * 3 / 4)); in testPorterDuffXfermode()
63 assertEquals(Color.RED, target.getPixel(WIDTH / 4, HEIGHT / 4)); in testPorterDuffXfermode()
64 assertEquals(Color.RED, target.getPixel(WIDTH / 4, HEIGHT * 3 / 4)); in testPorterDuffXfermode()
65 assertEquals(Color.TRANSPARENT, target.getPixel(WIDTH * 3 / 4, HEIGHT * 3 / 4)); in testPorterDuffXfermode()
72 assertEquals(Color.RED, target.getPixel(WIDTH / 4, HEIGHT / 4)); in testPorterDuffXfermode()
73 assertEquals(Color.MAGENTA, target.getPixel(WIDTH / 4, HEIGHT * 3 / 4)); in testPorterDuffXfermode()
74 assertEquals(Color.BLUE, target.getPixel(WIDTH * 3 / 4, HEIGHT * 3 / 4)); in testPorterDuffXfermode()
DPorterDuffColorFilterTest.java58 assertEquals(Color.RED, target.getPixel(width / 4, height / 4)); in testPorterDuffColorFilter()
59 int lowerLeft = target.getPixel(width / 4, height * 3 / 4); in testPorterDuffColorFilter()
62 int lowerRight = target.getPixel(width * 3 / 4, height * 3 / 4); in testPorterDuffColorFilter()
71 assertEquals(Color.RED, target.getPixel(width / 4, height / 4)); in testPorterDuffColorFilter()
72 assertEquals(Color.BLUE, target.getPixel(width / 4, height * 3 / 4)); in testPorterDuffColorFilter()
73 assertEquals(Color.BLUE, target.getPixel(width * 3 / 4, height * 3 / 4)); in testPorterDuffColorFilter()
81 assertEquals(Color.RED, target.getPixel(width / 4, height / 4)); in testPorterDuffColorFilter()
82 assertEquals(Color.CYAN, target.getPixel(width / 4, height * 3 / 4)); in testPorterDuffColorFilter()
83 assertEquals(Color.CYAN, target.getPixel(width * 3 / 4, height * 3 / 4)); in testPorterDuffColorFilter()
DColorMatrixColorFilterTest.java59 ColorUtils.verifyColor(Color.CYAN, bitmap.getPixel(0, 0)); in testColorMatrixColorFilter()
62 ColorUtils.verifyColor(Color.GREEN, bitmap.getPixel(0, 0)); in testColorMatrixColorFilter()
65 ColorUtils.verifyColor(Color.RED, bitmap.getPixel(0, 0)); in testColorMatrixColorFilter()
69 ColorUtils.verifyColor(Color.WHITE, bitmap.getPixel(0, 0)); in testColorMatrixColorFilter()
85 ColorUtils.verifyColor(Color.argb(128, 255, 0, 64), bitmap.getPixel(0, 0), 2); in testColorMatrixColorFilter()
89 ColorUtils.verifyColor(Color.CYAN, bitmap.getPixel(0, 0)); in testColorMatrixColorFilter()
96 ColorUtils.verifyColor(Color.CYAN, bitmap.getPixel(0, 0)); in testColorMatrixColorFilter()
100 ColorUtils.verifyColor(Color.BLUE, bitmap.getPixel(0, 0)); in testColorMatrixColorFilter()
DLightingColorFilterTest.java53 verifyColor(Color.MAGENTA, bitmap.getPixel(0, 0)); in testLightingColorFilter()
58 verifyColor(Color.BLUE, bitmap.getPixel(0, 0)); in testLightingColorFilter()
63 verifyColor(Color.CYAN, bitmap.getPixel(0, 0)); in testLightingColorFilter()
70 verifyColor(Color.GREEN, bitmap.getPixel(0, 0)); in testLightingColorFilter()
76 verifyColor(Color.MAGENTA, bitmap.getPixel(0, 0)); in testLightingColorFilter()
83 verifyColor(Color.argb(255, 30, 30, 30), bitmap.getPixel(0, 0)); in testLightingColorFilter()
91 verifyColor(Color.argb(0x80, 30, 30, 30), bitmap.getPixel(0, 0)); in testLightingColorFilter()
DComposeShaderTest.java67 int pixel = bitmap.getPixel(x, y); in testPorterDuff()
100 int pixel = bitmap.getPixel(x, y); in testBlendMode()
135 assertEquals(Color.WHITE, bitmap.getPixel(0, 0)); in testXfermode()
165 assertEquals(Color.WHITE, bitmap.getPixel(1, 1)); in testChildLocalMatrix()
172 assertEquals(Color.WHITE, bitmap.getPixel(2, 2)); in testChildLocalMatrix()
180 assertEquals(Color.WHITE, bitmap.getPixel(2, 2)); in testChildLocalMatrix()
188 assertEquals(Color.RED, bitmap.getPixel(2, 2)); in testChildLocalMatrix()
189 assertEquals(Color.CYAN, bitmap.getPixel(2, 1)); in testChildLocalMatrix()
DBlurMaskFilterTest.java74 verifyColor(color, bitmap.getPixel(x, y), alphaTolerance); in verifyQuadrants()
75 verifyColor(color, bitmap.getPixel(right - x, y), alphaTolerance); in verifyQuadrants()
76 verifyColor(color, bitmap.getPixel(x, bottom - y), alphaTolerance); in verifyQuadrants()
77 verifyColor(color, bitmap.getPixel(right - x, bottom - y), alphaTolerance); in verifyQuadrants()
DPaintFlagsDrawFilterTest.java81 pixelWithoutFilter = bitmapWithoutFilter.getPixel(i, j); in delta()
82 pixelWithFilter = bitmapWithFilter.getPixel(i, j); in delta()
98 int pixel = bitmap.getPixel(x, y); in verifyUnderline()
173 int color = bitmap.getPixel(i, j); in verifyContainsNonBW()
189 int color = bitmap.getPixel(i, j); in verifyContainsOnlyBlackAndWhite()
DDashPathEffectTest.java75 assertEquals(FOREGROUND, bitmap.getPixel(x, y)); in testDashPathEffect()
77 assertEquals(BACKGROUND, bitmap.getPixel(x, y)); in testDashPathEffect()
80 assertEquals(BACKGROUND, bitmap.getPixel(x, y)); in testDashPathEffect()
DBitmapTest.java165 + dst, Color.BLACK, dstBitmap.getPixel(0, 0)); in testCopyConfigs()
168 + dst, Color.WHITE, dstBitmap.getPixel(0, 0)); in testCopyConfigs()
344 ColorUtils.verifyColor(expected[0], observed.getPixel(0, 0)); in verify2x2BitmapContents()
345 ColorUtils.verifyColor(expected[1], observed.getPixel(1, 0)); in verify2x2BitmapContents()
346 ColorUtils.verifyColor(expected[2], observed.getPixel(0, 1)); in verify2x2BitmapContents()
347 ColorUtils.verifyColor(expected[3], observed.getPixel(1, 1)); in verify2x2BitmapContents()
582 bitmap.getPixel(0, 0); in testGenerationId()
636 assertEquals(0xffff0000, mBitmap.getPixel(10, 10)); in testEraseColor()
637 assertEquals(0xffff0000, mBitmap.getPixel(50, 50)); in testEraseColor()
706 assertEquals(mBitmap.getPixel(0, 0), result.toArgb()); in testGetColor()
[all …]
DComposePathEffectTest.java75 assertEquals(expected.getPixel(x, y), actual.getPixel(x, y)); in testComposePathEffect()
DPictureTest.java155 assertEquals(Color.BLUE, bitmap.getPixel(0, 0)); in verifyBitmap()
157 assertEquals(Color.RED, bitmap.getPixel(x, 0)); in verifyBitmap()
162 assertEquals(Color.GREEN, bitmap.getPixel(x, y)); in verifyBitmap()
/cts/common/device-side/util-axt/src/com/android/compatibility/common/util/
DBitmapUtils.java71 if (bmp1.getPixel(i, j) != bmp2.getPixel(i, j)) { in compareBitmaps()
98 if (bmp1.getPixel(i, j) != bmp2.getPixel(i, j)) { in compareBitmaps()
148 int firstColor = bitmap.getPixel(0, 0); in logIfBitmapSolidColor()
151 if (bitmap.getPixel(x, y) != firstColor) { in logIfBitmapSolidColor()
/cts/common/device-side/util/src/com/android/compatibility/common/util/
DBitmapUtils.java71 if (bmp1.getPixel(i, j) != bmp2.getPixel(i, j)) { in compareBitmaps()
98 if (bmp1.getPixel(i, j) != bmp2.getPixel(i, j)) { in compareBitmaps()
148 int firstColor = bitmap.getPixel(0, 0); in logIfBitmapSolidColor()
151 if (bitmap.getPixel(x, y) != firstColor) { in logIfBitmapSolidColor()
/cts/tests/tests/graphics/src/android/graphics/drawable/cts/
DColorDrawableTest.java143 assertEquals(Color.WHITE, DrawableTestUtils.getPixel(d, 0, 0)); in testSetColorFilter()
146 assertEquals(Color.BLACK, DrawableTestUtils.getPixel(d, 0, 0)); in testSetColorFilter()
149 assertEquals(Color.BLACK, DrawableTestUtils.getPixel(d, 0, 0)); in testSetColorFilter()
164 assertEquals(Color.WHITE, DrawableTestUtils.getPixel(d, 0, 0)); in testSetTint()
168 assertEquals(Color.BLACK, DrawableTestUtils.getPixel(d, 0, 0)); in testSetTint()
178 final int pixel = b.getPixel(0, 0); in testDraw()
DAdaptiveIconDrawableTest.java238 assertEquals(255, Color.alpha(bitmap.getPixel(50, 50))); in testSetAlpha()
243 assertEquals(200, Color.alpha(bitmap.getPixel(50, 50))); in testSetAlpha()
248 assertEquals(100, Color.alpha(bitmap.getPixel(50, 50))); in testSetAlpha()
375 int ra = (a.getPixel(i, j) >> 16) & 0xff; in equalBitmaps()
376 int ga = (a.getPixel(i, j) >> 8) & 0xff; in equalBitmaps()
377 int ba = a.getPixel(i, j) & 0xff; in equalBitmaps()
378 int rb = (b.getPixel(i, j) >> 16) & 0xff; in equalBitmaps()
379 int gb = (b.getPixel(i, j) >> 8) & 0xff; in equalBitmaps()
380 int bb = b.getPixel(i, j) & 0xff; in equalBitmaps()
381 if (region.contains(i, j) && a.getPixel(i, j) != b.getPixel(i, j) ) { in equalBitmaps()
DDrawableTestUtils.java173 int idealColor = expected.getPixel(x, y); in compareImages()
174 int givenColor = actual.getPixel(x, y); in compareImages()
211 public static int getPixel(Drawable d, int x, int y) { in getPixel() method in DrawableTestUtils
219 final int pixel = b.getPixel(x, y); in getPixel()
DTransitionDrawableTest.java157 int colorFrom = mBitmap.getPixel(0, 0); in testReverseTransition()
165 colorFrom = mBitmap.getPixel(0, 0); in testReverseTransition()
215 assertEquals(color, bmp.getPixel(i, j)); in verifyColorFillRect()
223 assertTrue(color != bmp.getPixel(i, j)); in verifyColorNotFillRect()
/cts/tests/tests/graphics/src/android/graphics/drawable/shapes/cts/
DPathShapeTest.java76 assertEquals(TEST_COLOR_1, bitmap.getPixel(50, 50)); in testDraw()
87 if (bitmap.getPixel(25, i) == TEST_COLOR_2) { in testDraw()
90 if (bitmap.getPixel(i, 25) == TEST_COLOR_2) { in testDraw()
93 if (bitmap.getPixel(i, i) == TEST_COLOR_2) { in testDraw()
DRoundRectShapeTest.java87 assertEquals(0, bitmap.getPixel(0, 0)); in testDraw()
88 assertEquals(TEST_COLOR_1, bitmap.getPixel(TEST_WIDTH / 2, 0)); in testDraw()
92 assertEquals(0, bitmap.getPixel(0, 0)); in testDraw()
93 assertEquals(TEST_COLOR_2, bitmap.getPixel(TEST_WIDTH / 2, 0)); in testDraw()
/cts/tests/tests/view/src/android/view/cts/
DTextureViewTest.java101 assertEquals(Color.WHITE, getPixel(window, center)); in testFirstFrames()
211 screenshot.getPixel(10, texturePos.top - 10)); in testTransformScale()
213 screenshot.getPixel(10, texturePos.bottom + 10)); in testTransformScale()
215 screenshot.getPixel(texturePos.left + 10, texturePos.top + 10)); in testTransformScale()
217 screenshot.getPixel(texturePos.right - 10, texturePos.top + 10)); in testTransformScale()
219 screenshot.getPixel(texturePos.left + 10, texturePos.bottom - 10)); in testTransformScale()
221 screenshot.getPixel(texturePos.right - 10, texturePos.bottom - 10)); in testTransformScale()
444 int color = dstBitmap.getPixel(0, 0); in verify()
532 private int getPixel(Window window, Point point) { in getPixel() method in TextureViewTest
537 int pixel = screenshot.getPixel(point.x, point.y); in getPixel()
[all …]
/cts/tests/tests/renderscript/src/android/renderscript/cts/refocus/
DImageCompare.java67 int pixel1 = bitmap1.getPixel(x, y); in psnr()
68 int pixel2 = bitmap2.getPixel(x, y); in psnr()
/cts/tests/tests/transition/src/android/transition/cts/
DFadeTest.java260 avg0 += getIntensity(bitmap1.getPixel(xStart + x, yStart + y)); in getMeans()
261 avg1 += getIntensity(bitmap2.getPixel(xStart + x, yStart + y)); in getMeans()
281 double v0 = getIntensity(bitmap1.getPixel(xStart + x, yStart + y)) - mean0; in getVariances()
282 double v1 = getIntensity(bitmap2.getPixel(xStart + x, yStart + y)) - mean1; in getVariances()
313 if (bitmap.getPixel(xStart + x, yStart + y) != Color.WHITE) { in isWindowWhite()

1234