Home
last modified time | relevance | path

Searched refs:screenshot (Results 1 – 25 of 32) sorted by relevance

12

/cts/tests/framework/base/windowmanager/src/android/server/wm/animations/
DBlurTests.java159 Bitmap screenshot = takeScreenshot(); in testBlurBehindSimple() local
160 assertBlurBehind(screenshot, windowFrame); in testBlurBehindSimple()
161 assertNoBackgroundBlur(screenshot, windowFrame); in testBlurBehindSimple()
168 screenshot = takeScreenshot(); in testBlurBehindSimple()
169 assertNoBlurBehind(screenshot, windowFrame); in testBlurBehindSimple()
170 assertNoBackgroundBlur(screenshot, windowFrame); in testBlurBehindSimple()
224 final Bitmap screenshot = takeScreenshot(); in testNoBlurBehindWhenBlurDisabled() local
225 assertBlurBehind(screenshot, windowFrame); in testNoBlurBehindWhenBlurDisabled()
226 assertNoBackgroundBlur(screenshot, windowFrame); in testNoBlurBehindWhenBlurDisabled()
253 Bitmap screenshot = takeScreenshot(); in testBackgroundBlurActivatesFallbackDynamically() local
[all …]
DLocationOnScreenTests.java162 final Bitmap screenshot = getInstrumentation().getUiAutomation().takeScreenshot(); in findTestColorsInScreenshot() local
167 if (isTestColors(screenshot, guess.x, guess.y)) { in findTestColorsInScreenshot()
171 for (int y = 0; y < screenshot.getHeight(); y++) { in findTestColorsInScreenshot()
172 for (int x = 0; x < screenshot.getWidth() - 1; x++) { in findTestColorsInScreenshot()
173 if (isTestColors(screenshot, x, y)) { in findTestColorsInScreenshot()
180 BitmapUtils.saveBitmap(screenshot, path, file); in findTestColorsInScreenshot()
186 private boolean isTestColors(Bitmap screenshot, int x, int y) { in isTestColors() argument
187 return sameColorWithinTolerance(screenshot.getPixel(x, y), TEST_COLOR_1) in isTestColors()
188 && sameColorWithinTolerance(screenshot.getPixel(x + 1, y), TEST_COLOR_2); in isTestColors()
/cts/hostsidetests/devicepolicy/app/DeviceAndProfileOwner/src/com/android/cts/deviceandprofileowner/
DScreenCaptureDisabledTest.java55 Bitmap screenshot = null; in testScreenCaptureImpossible() local
59 screenshot = takeScreenshot(); in testScreenCaptureImpossible()
60 if (screenshot == null) break; in testScreenCaptureImpossible()
62 assertWithMessage("screenshot").that(screenshot).isNull(); in testScreenCaptureImpossible()
66 Bitmap screenshot = null; in testScreenCapturePossible() local
70 screenshot = takeScreenshot(); in testScreenCapturePossible()
71 if (screenshot != null) break; in testScreenCapturePossible()
73 assertWithMessage("screenshot").that(screenshot).isNotNull(); in testScreenCapturePossible()
77 Bitmap screenshot = getInstrumentation().getUiAutomation().takeScreenshot(); in takeScreenshot() local
78 Log.d(TAG, "takeScreenshot(): got " + screenshot); in takeScreenshot()
[all …]
/cts/tests/bugreport/src/android/bugreport/cts/
DBugreportManagerTest.java133 String screenshot = brFiles.second; in testTelephonyBugreport() local
138 assertThat(screenshot).isNull(); in testTelephonyBugreport()
147 String screenshot = brFiles.second; in testFullBugreport() local
152 assertScreenshotFileNameCorrect(screenshot); in testFullBugreport()
153 assertThatFileisNotEmpty(screenshot); in testFullBugreport()
162 String screenshot = brFiles.second; in testInteractiveBugreport() local
169 assertScreenshotFileNameCorrect(screenshot); in testInteractiveBugreport()
170 assertThatFileisNotEmpty(screenshot); in testInteractiveBugreport()
172 assertThat(screenshot).isNull(); in testInteractiveBugreport()
182 String screenshot = brFiles.second; in testWifiBugreport() local
[all …]
/cts/hostsidetests/devicepolicy/app/Assistant/src/com/android/cts/devicepolicy/assistapp/
DMyInteractionSessionService.java45 public void onHandleScreenshot(Bitmap screenshot) { in onHandleScreenshot() argument
46 Log.d(TAG, "onHandleScreenshot() called with: screenshot = [" + screenshot + "]"); in onHandleScreenshot()
49 intent.putExtra(KEY_HAS_SCREENSHOT, screenshot != null); in onHandleScreenshot()
/cts/tests/tests/assist/service/src/android/assist/service/
DMainInteractionSession.java242 public void onHandleScreenshot(/*@Nullable*/ Bitmap screenshot) { in onHandleScreenshot() argument
243 Log.i(TAG, String.format("onHandleScreenshot - Screenshot: %s", screenshot)); in onHandleScreenshot()
244 super.onHandleScreenshot(screenshot); in onHandleScreenshot()
246 if (screenshot != null) { in onHandleScreenshot()
250 boolean screenshotMatches = compareScreenshot(screenshot, mCurColor); in onHandleScreenshot()
262 private boolean compareScreenshot(Bitmap screenshot, int color) { in compareScreenshot() argument
274 Point size = new Point(screenshot.getWidth(), screenshot.getHeight()); in compareScreenshot()
276 screenshot.getPixels(pixels, 0, size.x, 0, 0, size.x, size.y); in compareScreenshot()
281 Bitmap displayAreaScreenshot = Bitmap.createBitmap(screenshot, mDisplayAreaBounds.left, in compareScreenshot()
/cts/tests/tests/systemui/src/android/systemui/cts/
DScreenshotTestRule.java21 import androidx.test.runner.screenshot.BasicScreenCaptureProcessor;
22 import androidx.test.runner.screenshot.ScreenCapture;
23 import androidx.test.runner.screenshot.Screenshot;
/cts/tests/inputmethod/util/src/android/view/inputmethod/cts/util/
DInputMethodVisibilityVerifier.java52 final Bitmap screenshot = uiAutomation.takeScreenshot(); in containsWatermark() local
53 assertNotNull(screenshot); in containsWatermark()
54 return Watermark.detect(screenshot); in containsWatermark()
/cts/tests/accessibilityservice/src/android/accessibilityservice/cts/
DAccessibilityTakeScreenshotTest.java389 private boolean doesScreenshotContainColor(ScreenshotResult screenshot, int color) { in doesScreenshotContainColor() argument
390 final Bitmap bitmap = Bitmap.wrapHardwareBuffer(screenshot.getHardwareBuffer(), in doesScreenshotContainColor()
391 screenshot.getColorSpace()).copy(Bitmap.Config.ARGB_8888, false); in doesScreenshotContainColor()
412 private void verifyScreenshotResult(AccessibilityService.ScreenshotResult screenshot) { in verifyScreenshotResult() argument
413 verifyScreenshotResult(screenshot, mDisplaySize.x, mDisplaySize.y, mStartTestingTime); in verifyScreenshotResult()
416 private void verifyScreenshotResult(AccessibilityService.ScreenshotResult screenshot, in verifyScreenshotResult() argument
418 assertThat(screenshot).isNotNull(); in verifyScreenshotResult()
419 assertThat(screenshot.getTimestamp()).isGreaterThan(timestampBeforeTakeScreenshot); in verifyScreenshotResult()
421 final HardwareBuffer hardwareBuffer = screenshot.getHardwareBuffer(); in verifyScreenshotResult()
426 final ColorSpace colorSpace = screenshot.getColorSpace(); in verifyScreenshotResult()
/cts/tests/input/src/android/input/cts/
DPointerIconTest.kt54 import platform.test.screenshot.GoldenPathManager
55 import platform.test.screenshot.PathConfig
56 import platform.test.screenshot.ScreenshotTestRule
57 import platform.test.screenshot.assertAgainstGolden
58 import platform.test.screenshot.matchers.AlmostPerfectMatcher
59 import platform.test.screenshot.matchers.BitmapMatcher
/cts/tests/tests/uirendering/src/android/uirendering/cts/runner/
DUiRenderingRunner.java78 Bitmap screenshot = InstrumentationRegistry.getInstrumentation() in onCreate()
80 BitmapDumper.dumpBitmap(screenshot, "fullscreenshot"); in onCreate()
/cts/tests/surfacecontrol/surfacevalidator/src/android/view/cts/surfacevalidator/
DBitmapPixelChecker.java155 Bitmap screenshot = in takeScreenshot() local
158 assertNotNull("Failed to generate a screenshot", screenshot); in takeScreenshot()
159 Bitmap swBitmap = screenshot.copy(Bitmap.Config.ARGB_8888, false); in takeScreenshot()
160 screenshot.recycle(); in takeScreenshot()
/cts/tests/tests/view/src/android/view/cts/
DTextureViewTest.java211 Bitmap screenshot = Bitmap.createBitmap(100, 100, Bitmap.Config.ARGB_8888); in testRotateScale() local
212 int result = new SynchronousPixelCopy().request(window, viewPos, screenshot); in testRotateScale()
215 assertBitmapQuadColor(screenshot, in testRotateScale()
253 Bitmap screenshot = Bitmap.createBitmap(viewPos.width(), viewPos.height(), in testTransformScale() local
255 int result = new SynchronousPixelCopy().request(window, viewPos, screenshot); in testTransformScale()
265 screenshot.getPixel(10, texturePos.top - 10)); in testTransformScale()
267 screenshot.getPixel(10, texturePos.bottom + 10)); in testTransformScale()
269 screenshot.getPixel(texturePos.left + 10, texturePos.top + 10)); in testTransformScale()
271 screenshot.getPixel(texturePos.right - 10, texturePos.top + 10)); in testTransformScale()
273 screenshot.getPixel(texturePos.left + 10, texturePos.bottom - 10)); in testTransformScale()
[all …]
DOWNERS8 ….java = file:platform/frameworks/base:/packages/SystemUI/src/com/android/systemui/screenshot/OWNERS
/cts/tests/surfacecontrol/src/android/view/surfacecontrol/cts/
DSurfaceSyncGroupTests.java193 Bitmap screenshot = mInstrumentation.getUiAutomation().takeScreenshot( in validateScreenshot() local
195 assertNotNull("Failed to generate a screenshot", screenshot); in validateScreenshot()
196 Bitmap swBitmap = screenshot.copy(Bitmap.Config.ARGB_8888, false); in validateScreenshot()
197 screenshot.recycle(); in validateScreenshot()
/cts/tests/tests/uirendering/src/android/uirendering/cts/testclasses/
DSurfaceViewTests.java596 Bitmap screenshot = mScreenshotter.takeScreenshot(testInfo);
599 screenshot, new ColorVerifier(Color.RED, 2), "");
607 screenshot = mScreenshotter.takeScreenshot(testInfo);
610 screenshot, new ColorVerifier(Color.BLUE, 2), "");
661 Bitmap screenshot = mScreenshotter.takeScreenshot(testInfo);
663 screenshot,
697 Bitmap screenshot = mScreenshotter.takeScreenshot(testInfo);
699 screenshot,
734 Bitmap screenshot = mScreenshotter.takeScreenshot(testInfo);
736 screenshot,
[all …]
/cts/tests/tests/textclassifier/src/android/view/textclassifier/cts/
DHelper.java53 final Bitmap screenshot = takeScreenshot(); in takeScreenshotAndSave() local
54 saveBitmapToFile(screenshot, file); in takeScreenshotAndSave()
/cts/tests/framework/base/windowmanager/src/android/server/wm/insets/
DWindowInsetsAnimationSynchronicityTests.java103 Bitmap screenshot = getInstrumentation().getUiAutomation().takeScreenshot(); in runTest() local
108 int imePositionApp = lowestPixelWithColor(APP_COLOR, 1, screenshot); in runTest()
109 int contentBottomMiddle = lowestPixelWithColor(APP_COLOR, center, screenshot); in runTest()
111 lowestPixelWithColor(BEHIND_IME_COLOR, center, screenshot); in runTest()
/cts/tests/devicepolicy/src/android/devicepolicy/cts/
DScreenCaptureDisabledTest.java501 private boolean checkScreenshotIsRedactedOrNull(Bitmap screenshot) { in checkScreenshotIsRedactedOrNull() argument
502 if (screenshot == null) { in checkScreenshotIsRedactedOrNull()
505 int width = screenshot.getWidth(); in checkScreenshotIsRedactedOrNull()
506 int height = screenshot.getHeight(); in checkScreenshotIsRedactedOrNull()
515 screenshot.getPixels(pixels, 0, width, 0, height / 4, width, height / 2); in checkScreenshotIsRedactedOrNull()
/cts/tests/tests/voiceinteraction/service/src/android/voiceinteraction/service/
DMainInteractionSession.java243 public void onHandleScreenshot(@Nullable Bitmap screenshot) { in onHandleScreenshot() argument
244 super.onHandleScreenshot(screenshot); in onHandleScreenshot()
245 Log.d(TAG, "onHandleScreenshot: " + screenshot); in onHandleScreenshot()
248 extras.putBoolean(EXTRA_RECEIVED, screenshot != null); in onHandleScreenshot()
/cts/tests/translation/src/android/translation/cts/
DHelper.java196 final Bitmap screenshot = takeScreenshot(); in takeScreenshotAndSave() local
197 saveBitmapToFile(screenshot, file); in takeScreenshotAndSave()
/cts/tests/accessibility/common/src/android/accessibility/cts/common/
DAccessibilityDumper.java155 final Bitmap screenshot = automation.takeScreenshot(); in dumpScreen() local
158 BitmapUtils.saveBitmap(screenshot, mRoot.toString(), filename); in dumpScreen()
/cts/tests/input/
DAndroid.bp54 "platform-screenshot-diff-core",
/cts/tests/tests/widget/src/android/widget/cts/
DHorizontalScrollViewTest.java979 Bitmap screenshot = getInstrumentation().getUiAutomation().takeScreenshot( in testSurfaceViewStretchAtEnd()
982 assertEquals(Color.RED, screenshot.getPixel( in testSurfaceViewStretchAtEnd()
1055 Bitmap screenshot = getInstrumentation().getUiAutomation().takeScreenshot( in testSurfaceViewStretchAtEndWithScale()
1061 int topLeftColor = screenshot.getPixel( in testSurfaceViewStretchAtEndWithScale()
1064 int topRightColor = screenshot.getPixel( in testSurfaceViewStretchAtEndWithScale()
1067 int bottomLeftColor = screenshot.getPixel( in testSurfaceViewStretchAtEndWithScale()
1070 int bottomRightColor = screenshot.getPixel( in testSurfaceViewStretchAtEndWithScale()
DScrollViewTest.java1051 Bitmap screenshot = getInstrumentation().getUiAutomation().takeScreenshot( in testSurfaceViewStretchAtEnd()
1054 assertEquals(Color.RED, screenshot.getPixel( in testSurfaceViewStretchAtEnd()
1126 Bitmap screenshot = getInstrumentation().getUiAutomation().takeScreenshot( in testSurfaceViewStretchAtEndWithScale()
1132 int topLeftColor = screenshot.getPixel( in testSurfaceViewStretchAtEndWithScale()
1137 int topRightColor = screenshot.getPixel( in testSurfaceViewStretchAtEndWithScale()
1142 int bottomLeftColor = screenshot.getPixel( in testSurfaceViewStretchAtEndWithScale()
1147 int bottomRightColor = screenshot.getPixel( in testSurfaceViewStretchAtEndWithScale()

12