Home
last modified time | relevance | path

Searched refs:width (Results 1 – 19 of 19) sorted by relevance

/test/screenshot/screenshot/src/main/java/androidx/test/screenshot/matchers/
DPixelPerfectMatcher.kt28 width: Int, in compareBitmaps()
36 val diffArray = IntArray(width * height) in compareBitmaps()
39 for (x in 0 until width) { in compareBitmaps()
40 val index = x + y * width in compareBitmaps()
53 val diff = Bitmap.createBitmap(diffArray, width, height, Bitmap.Config.ARGB_8888) in compareBitmaps()
DMSSIMMatcher.kt44 width: Int, in compareBitmaps()
47 val SSIMTotal = calculateSSIM(expected, given, width, height) in compareBitmaps()
57 val result = PixelPerfectMatcher().compareBitmaps(expected, given, width, height) in compareBitmaps()
61 internal fun calculateSSIM(ideal: IntArray, given: IntArray, width: Int, height: Int): Double { in calculateSSIM()
62 return calculateSSIM(ideal, given, 0, width, width, height) in calculateSSIM()
70 width: Int, in calculateSSIM()
79 while (currentWindowX < width) { in calculateSSIM()
80 val windowWidth = computeWindowSize(currentWindowX, width) in calculateSSIM()
DBitmapMatcher.kt33 fun compareBitmaps(expected: IntArray, given: IntArray, width: Int, height: Int): MatchResult
/test/screenshot/screenshot/src/androidTest/java/androidx/test/screenshot/
DMSSIMMatcherTest.kt41 first.width, in performDiff_sameBitmaps()
58 first.width, in performDiff_checkedAgainstUnchecked()
75 first.width, in performDiff_differentBorders()
92 first.width, in performDiff_fullscreen_differentBorders_dark()
109 first.width, in performDiff_differentBorders_dark()
126 first.width, in performDiff_fullscreen_movedToRight()
143 first.width, in performDiff_fullscreen_checkboxes_differentRadius()
DPixelPerfectMatcherTest.kt41 first.width, in performDiff_sameBitmaps()
58 first.width, in performDiff_sameSize_differentBorders()
/test/uiautomator/integration-tests/testapp/src/androidTest/java/androidx/test/uiautomator/testapp/
DMultiWindowTest.java60 int width = mDevice.getDisplayWidth(); in testMultiWindow_splitScreen() local
62 mDevice.click(width / 2, height / 4); in testMultiWindow_splitScreen()
63 mDevice.click(width / 2, 3 * height / 4); in testMultiWindow_splitScreen()
DUiDeviceTest.java317 int width = mDevice.getDisplayWidth(); in testClick() local
319 mDevice.click(width / 2, height / 2); in testClick()
333 int width = mDevice.getDisplayWidth(); in testSwipe() local
335 mDevice.swipe(width / 10, height / 2, 9 * width / 10, height / 2, 10); in testSwipe()
362 int width = mDevice.getDisplayWidth(); in testSwipe_withPointArray() local
365 Point point1 = new Point(width / 10, height / 2); in testSwipe_withPointArray()
366 Point point2 = new Point(width / 2, height / 2); in testSwipe_withPointArray()
367 Point point3 = new Point(9 * width / 10, height / 2); in testSwipe_withPointArray()
DMultiDisplayTest.java120 int width = 800; in testMultiDisplay_displayMetrics() local
123 String.format("wm size %dx%d -d %d", width, height, secondaryDisplayId)); in testMultiDisplay_displayMetrics()
125 assertEquals(width, mDevice.getDisplayWidth(secondaryDisplayId)); in testMultiDisplay_displayMetrics()
DUiObject2Test.java872 int pointX = objBounds.left + objBounds.width() / 3; in getPointInsideBounds()
880 int pointX = objBounds.right + objBounds.width() / 3; in getPointOutsideBounds()
/test/screenshot/screenshot/src/main/java/androidx/test/screenshot/
DScreenshotTestRule.kt195 if (actual.width != expected.width || actual.height != expected.height) { in assertBitmapAgainstGolden()
212 width = actual.width, in assertBitmapAgainstGolden()
364 val bitmapArray = IntArray(width * height) in toIntArray()
365 getPixels(bitmapArray, 0, width, 0, 0, width, height) in toIntArray()
/test/uiautomator/uiautomator/src/main/java/androidx/test/uiautomator/
DAccessibilityNodeInfoHelper.java41 static Rect getVisibleBoundsInScreen(AccessibilityNodeInfo node, int width, int height, in getVisibleBoundsInScreen() argument
43 return getVisibleBoundsInScreen(node, new Rect(0, 0, width, height), trimScrollableParent); in getVisibleBoundsInScreen()
DGestures.java112 end = new Point(area.right - (int)(area.width() * percent), area.centerY()); in swipeRect()
116 end = new Point(area.left + (int)(area.width() * percent), area.centerY()); in swipeRect()
192 int offsetX = (int) (area.width() / 2 * percent); in calcPinchCoordinates()
DUiObject.java303 if (rect.width() <= SWIPE_MARGIN_LIMIT * 2) { in swipeLeft()
305 rect.width(), SWIPE_MARGIN_LIMIT * 2)); in swipeLeft()
334 if (rect.width() <= SWIPE_MARGIN_LIMIT * 2) { in swipeRight()
336 rect.width(), SWIPE_MARGIN_LIMIT * 2)); in swipeRight()
874 if (rect.width() <= FINGER_TOUCH_HALF_WIDTH * 2) in pinchOut()
882 Point endPoint1 = new Point(rect.centerX() - (int)((rect.width()/2) * percentage), in pinchOut()
884 Point endPoint2 = new Point(rect.centerX() + (int)((rect.width()/2) * percentage), in pinchOut()
912 if (rect.width() <= FINGER_TOUCH_HALF_WIDTH * 2) in pinchIn()
915 Point startPoint1 = new Point(rect.centerX() - (int)((rect.width()/2) * percentage), in pinchIn()
917 Point startPoint2 = new Point(rect.centerX() + (int)((rect.width()/2) * percentage), in pinchIn()
DAccessibilityNodeInfoDumper.java66 int width, int height) throws IOException { in dumpNodeRec() argument
88 node, width, height, false).toShortString()); in dumpNodeRec()
105 dumpNodeRec(child, serializer, i, width, height); in dumpNodeRec()
DUiScrollable.java364 int swipeAreaAdjust = (int)(rect.width() * getSwipeDeadZonePercentage()); in scrollForward()
438 int swipeAreaAdjust = (int)(rect.width() * getSwipeDeadZonePercentage()); in scrollBackward()
DUiObject2.java1123 return new Rect(bounds.left + (int) (bounds.width() * mLeft), in apply()
1125 bounds.right - (int) (bounds.width() * mRight), in apply()
/test/uiautomator/uiautomator/src/main/java/androidx/test/uiautomator/internal/
DUtils.kt65 right = bitmap.width in joinLines()
74 bounds.width(), in joinLines()
/test/uiautomator/uiautomator/src/androidTest/java/androidx/test/uiautomator/
DUiDeviceTest.java101 int width = 800; in testGetDisplayMetrics() local
103 mDevice.executeShellCommand(String.format("wm size %dx%d", width, height)); in testGetDisplayMetrics()
105 Point expectedSizeDp = new Point(Math.round(width / density), in testGetDisplayMetrics()
108 assertEquals(width, mDevice.getDisplayWidth()); in testGetDisplayMetrics()
/test/uiautomator/integration-tests/testapp/src/main/java/androidx/test/uiautomator/testapp/
DUntilTestActivity.java76 scrollableTarget.getLayoutParams().width = 1; // Force horizontal scrollbar. in onCreate()