Home
last modified time | relevance | path

Searched refs:height (Results 1 – 25 of 325) sorted by relevance

12345678910>>...13

/cts/tests/tests/graphics/src/android/graphics/cts/
DPorterDuffColorFilterTest.java41 int height = 100; in testPorterDuffColorFilter() local
42 Bitmap b1 = Bitmap.createBitmap(width / 2, height, Config.ARGB_8888); in testPorterDuffColorFilter()
44 Bitmap b2 = Bitmap.createBitmap(width, height / 2, Config.ARGB_8888); in testPorterDuffColorFilter()
47 Bitmap target = Bitmap.createBitmap(width, height, Config.ARGB_8888); in testPorterDuffColorFilter()
56 canvas.drawBitmap(b2, 0, height / 2, p); in testPorterDuffColorFilter()
57 assertEquals(Color.RED, target.getPixel(width / 4, height / 4)); in testPorterDuffColorFilter()
58 int lowerLeft = target.getPixel(width / 4, height * 3 / 4); in testPorterDuffColorFilter()
61 int lowerRight = target.getPixel(width * 3 / 4, height * 3 / 4); in testPorterDuffColorFilter()
69 canvas.drawBitmap(b2, 0, height / 2, p); in testPorterDuffColorFilter()
70 assertEquals(Color.RED, target.getPixel(width / 4, height / 4)); in testPorterDuffColorFilter()
[all …]
DYuvImageTest.java95 int height = 100; in testYuvImage() local
96 byte[] yuv = new byte[width * height * 2]; in testYuvImage()
102 new YuvImage(yuv, FORMATS[i], width, height, null); in testYuvImage()
120 image = new YuvImage(yuv, FORMATS[i], width, height, null); in testYuvImage()
193 int height = mTestBitmaps[0].getHeight(); in testGetYuvData() local
195 int[] argb = new int[stride * height]; in testGetYuvData()
196 mTestBitmaps[0].getPixels(argb, 0, stride, 0, 0, width, height); in testGetYuvData()
197 byte[] yuv = convertArgbsToYuvs(argb, stride, height, ImageFormat.NV21); in testGetYuvData()
201 YuvImage image = new YuvImage(yuv, ImageFormat.NV21, width, height, strides); in testGetYuvData()
212 private void generateTestBitmaps(int width, int height) { in generateTestBitmaps() argument
[all …]
/cts/tests/tests/uirendering/src/android/uirendering/cts/util/
DBitmapAsserter.java59 int height = bitmap1.getHeight(); in assertBitmapsAreSimilar() local
61 if (width != bitmap2.getWidth() || height != bitmap2.getHeight()) { in assertBitmapsAreSimilar()
65 int[] pixels1 = new int[width * height]; in assertBitmapsAreSimilar()
66 int[] pixels2 = new int[width * height]; in assertBitmapsAreSimilar()
67 bitmap1.getPixels(pixels1, 0, width, 0, 0, width, height); in assertBitmapsAreSimilar()
68 bitmap2.getPixels(pixels2, 0, width, 0, 0, width, height); in assertBitmapsAreSimilar()
69 success = comparer.verifySame(pixels1, pixels2, 0, width, width, height); in assertBitmapsAreSimilar()
85 int height = bitmap.getHeight(); in assertBitmapIsVerified() local
86 int[] pixels = new int[width * height]; in assertBitmapIsVerified()
87 bitmap.getPixels(pixels, 0, width, 0, 0, width, height); in assertBitmapIsVerified()
[all …]
DBitmapDumper.java79 int height = idealBitmap.getHeight(); in dumpBitmaps() local
80 int[] testedArray = new int[width * height]; in dumpBitmaps()
81 int[] idealArray = new int[width * height]; in dumpBitmaps()
82 idealBitmap.getPixels(testedArray, 0, width, 0, 0, width, height); in dumpBitmaps()
83 testedBitmap.getPixels(idealArray, 0, width, 0, 0, width, height); in dumpBitmaps()
85 visualizerBitmap = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888); in dumpBitmaps()
86 visualizerBitmap.setPixels(visualizerArray, 0, width, 0, 0, width, height); in dumpBitmaps()
87 Bitmap croppedBitmap = Bitmap.createBitmap(testedBitmap, 0, 0, width, height); in dumpBitmaps()
/cts/tests/tests/uirendering/src/android/uirendering/cts/testinfrastructure/
DResourceModifier.java99 final float height = bitmap.getHeight() / 8.0f; in ResourceModifier() local
103 0.0f, height, width, height, width * 2, height, width * 4, height, in ResourceModifier()
104 0.0f, height * 2, width, height * 2, width * 2, height * 2, width * 3, height * 2, in ResourceModifier()
105 0.0f, height * 4, width, height * 4, width * 2, height * 4, width * 4, height * 4, in ResourceModifier()
/cts/tests/tests/renderscript/src/android/renderscript/cts/
DAllocationCopy2DRangeTest.java33 int height = random.nextInt(512); in testAllocationCopy2DRange() local
35 int[] inArray = new int[width * height]; in testAllocationCopy2DRange()
36 int[] outArray = new int[width * height]; in testAllocationCopy2DRange()
38 for (int i = 0; i < width * height; i++) { in testAllocationCopy2DRange()
44 typeBuilder.setX(width).setY(height); in testAllocationCopy2DRange()
47 mInAllocation.copy2DRangeFrom(0, 0, width, height, inArray); in testAllocationCopy2DRange()
49 mScript.set_height(height); in testAllocationCopy2DRange()
57 compareTwoArrays(inArray, outArray, width*height)); in testAllocationCopy2DRange()
DAllocationCopyToTest.java231 int height = random.nextInt(128); in test_Allocationcopy2DRangeTo_Byte() local
233 int yoff = random.nextInt(height); in test_Allocationcopy2DRangeTo_Byte()
235 int ycount = height - yoff; in test_Allocationcopy2DRangeTo_Byte()
243 typeBuilder.setX(width).setY(height); in test_Allocationcopy2DRangeTo_Byte()
262 int height = random.nextInt(128); in test_Allocationcopy2DRangeTo_Short_Helper() local
264 int yoff = random.nextInt(height); in test_Allocationcopy2DRangeTo_Short_Helper()
266 int ycount = height - yoff; in test_Allocationcopy2DRangeTo_Short_Helper()
277 typeBuilder.setX(width).setY(height); in test_Allocationcopy2DRangeTo_Short_Helper()
307 int height = random.nextInt(128); in test_Allocationcopy2DRangeTo_Int() local
309 int yoff = random.nextInt(height); in test_Allocationcopy2DRangeTo_Int()
[all …]
DrsAllocationCopyTest.java265 int height = random.nextInt(128); in test_rsAllocationCopy2D_Byte() local
267 int yOff = random.nextInt(height); in test_rsAllocationCopy2D_Byte()
269 int yCount = random.nextInt(height - yOff); in test_rsAllocationCopy2D_Byte()
270 int arr_len = width * height; in test_rsAllocationCopy2D_Byte()
277 typeBuilder.setX(width).setY(height); in test_rsAllocationCopy2D_Byte()
295 for (int i = 0; i < height; i++) { in test_rsAllocationCopy2D_Byte()
319 int height = random.nextInt(128); in test_rsAllocationCopy2D_Short() local
321 int yOff = random.nextInt(height); in test_rsAllocationCopy2D_Short()
323 int yCount = random.nextInt(height - yOff); in test_rsAllocationCopy2D_Short()
324 int arr_len = width * height; in test_rsAllocationCopy2D_Short()
[all …]
DYuvTest.java24 int height; field in YuvTest
54 return (height + 1) / 2; in getCHeight()
60 height = h; in makeYuvBuffer()
87 … return Allocation.createTyped(mRS, Type.createXY(mRS, Element.RGBA_8888(mRS), width, height)); in makeOutput()
91 return Allocation.createTyped(mRS, Type.createXY(mRS, Element.F32_4(mRS), width, height)); in makeOutput_f4()
102 byte tmp[] = new byte[(width * height) + (getCWidth() * getCHeight() * 2)]; in testV17()
104 for (int j = 0; j < (width * height); j++) { in testV17()
149 tb.setY(height); in test_NV21()
153 byte tmp[] = new byte[(width * height) + (getCWidth() * getCHeight() * 2)]; in test_NV21()
155 for (int j = 0; j < (width * height); j++) { in test_NV21()
[all …]
/cts/apps/CtsVerifier/src/com/android/cts/verifier/camera/fov/
DSelectableResolution.java25 public final int height; field in SelectableResolution
30 public SelectableResolution(int cameraId, int width, int height) { in SelectableResolution() argument
33 this.height = height; in SelectableResolution()
40 return "Cam " + cameraId + ": " + width + " x " + height + " - " in toString()
DSize.java24 public final int height; field in Size
26 public Size(int width, int height) { in Size() argument
28 this.height = height; in Size()
/cts/tests/tests/uirendering/src/android/uirendering/cts/testclasses/
DShaderTests.java48 public void draw(Canvas canvas, int width, int height) { in testSinglePixelBitmapShader()
55 canvas.drawRect(0, 0, width, height, mPaint); in testSinglePixelBitmapShader()
68 public void draw(Canvas canvas, int width, int height) { in testSinglePixelComposeShader()
86 canvas.drawRect(0, 0, width, height, mPaint); in testSinglePixelComposeShader()
110 public void draw(Canvas canvas, int width, int height) { in testComplexShaderUsage()
112 mBitmap = Bitmap.createBitmap(width, height, Bitmap.Config.ALPHA_8); in testComplexShaderUsage()
116 bitmapCanvas.drawCircle(width / 2, height / 2, radius, mPaint); in testComplexShaderUsage()
120 width, height, Bitmap.Config.ALPHA_8); in testComplexShaderUsage()
123 bitmapCanvas.drawCircle(width / 2, height, radius, mPaint); in testComplexShaderUsage()
129 width / 2, height / 2, radius, in testComplexShaderUsage()
[all …]
DExactCanvasTests.java50 .addCanvasClient((canvas, width, height) -> { in testBlueRect()
62 .addCanvasClient((canvas, width, height) -> { in testPoints()
77 .addCanvasClient((canvas, width, height) -> { in testBlackRectWithStroke()
92 .addCanvasClient((canvas, width, height) -> { in testBlackLineOnGreenBack()
105 .addCanvasClient((canvas, width, height) -> { in testDrawRedRectOnBlueBack()
117 .addCanvasClient((canvas, width, height) -> { in testDrawLine()
132 .addCanvasClient((canvas, width, height) -> canvas.drawColor(Color.WHITE)) in testDrawWhiteScreen()
140 .addCanvasClient((canvas, width, height) -> { in testBasicText()
163 .addCanvasClient((canvas, width, height) -> { in testTextOnPath()
175 .addCanvasClient((canvas, width, height) -> { in testTextOnPathUsingPicture()
[all …]
DRgba16fTests.java45 .addCanvasClient("RGBA16F_TransferFunctions", (canvas, width, height) -> { in testTransferFunctions()
51 height / (float) bitmap.getHeight()); in testTransferFunctions()
66 .addCanvasClient("RGBA16F_TransferFunctions", (canvas, width, height) -> { in testAlpha()
72 height / (float) bitmap.getHeight()); in testAlpha()
90 .addCanvasClient("RGBA16F_Masked", (canvas, width, height) -> { in testMasked()
108 height / (float) bitmap.getHeight()); in testMasked()
124 .addCanvasClient("RGBA16F_TransferFunctions_Shader", (canvas, width, height) -> { in testTransferFunctionsShader()
131 canvas.drawRect(0.0f, 0.0f, width, height, p); in testTransferFunctionsShader()
145 .addCanvasClient("RGBA16F_TransferFunctions_Mirror", (canvas, width, height) -> { in testMirroredTransferFunctions()
153 height / (float) bitmap.getHeight()); in testMirroredTransferFunctions()
/cts/tests/tests/rscpp/src/android/cts/rscpp/
DRSYuvTest.java32 int height; field in RSYuvTest
44 return (height + 1) / 2; in getCHeight()
50 height = h; in makeYuvBuffer()
77 … return Allocation.createTyped(mRS, Type.createXY(mRS, Element.RGBA_8888(mRS), width, height)); in makeOutput()
88 byte tmp[] = new byte[(width * height) + (getCWidth() * getCHeight() * 2)]; in testV17()
90 for (int j = 0; j < (width * height); j++) { in testV17()
105 byte[] nativeByteAlloc = new byte[width * height * 4]; in testV17()
106 yuvTest(this.getContext().getCacheDir().toString(), width, height, tmp, nativeByteAlloc, 0); in testV17() local
123 tb.setY(height); in test_YV12()
127 byte tmp[] = new byte[(width * height) + (getCWidth() * getCHeight() * 2)]; in test_YV12()
[all …]
/cts/tests/tests/mediastress/preconditions/app/src/android/mediastress/cts/preconditions/app/
DMediaPreparerAppTest.java61 private final int height; field in MediaPreparerAppTest.Resolution
63 private Resolution(int width, int height) { in Resolution() argument
65 this.height = height; in Resolution()
73 this.height = Integer.parseInt(matcher.group(HEIGHT_INDEX)); in Resolution()
78 return String.format("%dx%d", width, height); in toString()
88 int height = 0; in testGetResolutions() local
92 height = Math.max(height, format.getInteger(MediaFormat.KEY_HEIGHT)); in testGetResolutions()
98 Resolution fileResolution = new Resolution(width, height); in testGetResolutions()
/cts/tests/camera/src/android/hardware/cts/
DCamera_SizeTest.java90 float jpegAspect = largestJpegDimen.width / (float) largestJpegDimen.height; in testMaxAspectRatios()
92 largestPreviewDimen.width / (float) largestPreviewDimen.height; in testMaxAspectRatios()
97 largestPreviewDimen.height + ") should have the same aspect ratio " + in testMaxAspectRatios()
99 ", h=" + largestJpegDimen.height + ")"); in testMaxAspectRatios()
108 private void checkSize(Parameters parameters, int width, int height) { in checkSize() argument
109 parameters.setPictureSize(width, height); in checkSize()
111 assertEquals(height, parameters.getPictureSize().height); in checkSize()
/cts/tests/tests/widget/src/android/widget/cts/
DTableLayout_LayoutParamsTest.java57 assertEquals(TableLayout.LayoutParams.WRAP_CONTENT, layoutParams.height); in testConstructor()
62 assertEquals(TableLayout.LayoutParams.WRAP_CONTENT, layoutParams.height); in testConstructor()
67 assertEquals(300, layoutParams.height); in testConstructor()
72 assertEquals(350, layoutParams.height); in testConstructor()
78 assertEquals(360, layoutParams.height); in testConstructor()
83 assertEquals(420, layoutParams.height); in testConstructor()
88 assertEquals(400, layoutParams.height); in testConstructor()
93 assertEquals(650, layoutParams.height); in testConstructor()
101 assertEquals(300, mockLayoutParams.height); in testSetBaseAttributes()
111 assertEquals(600, mockLayoutParams.height); in testSetBaseAttributes()
[all …]
DRadioGroup_LayoutParamsTest.java60 assertEquals(Integer.MAX_VALUE, mLayoutParams.height); in testConstructor()
65 assertEquals(Integer.MIN_VALUE, mLayoutParams.height); in testConstructor()
71 assertEquals(Integer.MAX_VALUE, mLayoutParams.height); in testConstructor()
77 assertEquals(Integer.MAX_VALUE, mLayoutParams.height); in testConstructor()
82 assertEquals(60, mLayoutParams.height); in testConstructor()
87 assertEquals(200, mLayoutParams.height); in testConstructor()
102 assertEquals(20, mLayoutParams.height); in testConstructor()
119 assertEquals(RadioGroup.LayoutParams.MATCH_PARENT, mLayoutParams.height); in testConstructor()
123 assertEquals(RadioGroup.LayoutParams.WRAP_CONTENT, mLayoutParams.height); in testConstructor()
146 assertEquals(RadioGroup.LayoutParams.WRAP_CONTENT, layoutParams.height); in testSetBaseAttributes()
[all …]
/cts/hostsidetests/services/activityandwindowmanager/windowmanager/frametestapp/src/android/server/frametestapp/
DDialogTestActivity.java117 params.height = WindowManager.LayoutParams.MATCH_PARENT; in testMatchParent()
124 params.height = WindowManager.LayoutParams.MATCH_PARENT; in testMatchParentLayoutInOverscan()
133 params.height = 200; in testExplicitSize()
140 params.height = 200; in testExplicitSizeTopLeftGravity()
148 params.height = 200; in testExplicitSizeBottomRightGravity()
156 params.height = 100000; in testOversizedDimensions()
163 params.height = 5000; in testOversizedDimensionsNoLimits()
172 params.height = WindowManager.LayoutParams.MATCH_PARENT; in testExplicitPositionMatchParent()
181 params.height = WindowManager.LayoutParams.MATCH_PARENT; in testExplicitPositionMatchParentNoLimits()
201 params.height = 200; in testWithMargins()
/cts/tests/tests/media/src/android/media/cts/
DNativeEncoderTest.java74 private boolean testEncode(int res, String mime, int width, int height) { in testEncode() argument
79 mime, width, height); in testEncode()
82 String mime, int width, int height); in testEncodeSurfaceNative() argument
110 private boolean testEncodeDynamicSyncFrame(int res, String mime, int width, int height) { in testEncodeDynamicSyncFrame() argument
115 mime, width, height); in testEncodeDynamicSyncFrame()
118 String mime, int width, int height); in testEncodeSurfaceDynamicSyncFrameNative() argument
146 private boolean testEncodeDynamicBitrate(int res, String mime, int width, int height) { in testEncodeDynamicBitrate() argument
151 mime, width, height); in testEncodeDynamicBitrate()
154 String mime, int width, int height); in testEncodeSurfaceDynamicBitrateNative() argument
182 private boolean testEncodePersistentSurface(int res, String mime, int width, int height) { in testEncodePersistentSurface() argument
[all …]
DIvfWriter.java56 String filename, String mimeType, int width, int height, int scale, in IvfWriter() argument
61 mHeight = height; in IvfWriter()
79 public IvfWriter(String filename, String mimeType, int width, int height) throws IOException { in IvfWriter() argument
80 this(filename, mimeType, width, height, 1, 1000000); in IvfWriter()
117 int frameCount, int width, int height, int scale, int rate, String mimeType) { in makeIvfHeader() argument
130 lay16Bits(ivfHeader, 14, height); in makeIvfHeader()
DMediaPlayerTestBase.java201 protected void playVideoTest(String path, int width, int height) throws Exception { in playVideoTest() argument
202 playVideoWithRetries(path, width, height, 0); in playVideoTest()
205 protected void playVideoWithRetries(String path, Integer width, Integer height, int playTime) in playVideoWithRetries() argument
211 playLoadedVideo(width, height, playTime); in playVideoWithRetries()
222 protected void playVideoTest(int resid, int width, int height) throws Exception { in playVideoTest() argument
227 playLoadedVideo(width, height, 0); in playVideoTest()
238 Integer width, Integer height, int playTime) throws Exception { in playVideoWithRetries() argument
244 playLoadedVideo(width, height, playTime); in playVideoWithRetries()
267 protected void playLoadedVideo(final Integer width, final Integer height, int playTime) in playLoadedVideo() argument
273 (height != null && height.intValue() == -1); in playLoadedVideo()
[all …]
/cts/hostsidetests/sustainedperf/shadertoy_android/jni/
Dhooks_android.cpp19 extern void Init(int width, int height);
24 …ICALL Java_com_android_gputest_GLtestLib_init(JNIEnv * env, jobject obj, jint width, jint height);
28 …__attribute__((unused)) JNIEnv * env,__attribute__((unused)) jobject obj, jint width, jint height) in Java_com_android_gputest_GLtestLib_init() argument
30 Init(width, height); in Java_com_android_gputest_GLtestLib_init()
/cts/tests/tests/nativehardware/jni/
DAHardwareBufferTest.cpp61 if (bufferDesc.height != desc.height) in CheckAHardwareBufferMatchesDesc()
62 return BuildFailureMessage(desc.height, bufferDesc.height, "heights"); in CheckAHardwareBufferMatchesDesc()
97 desc.height = 4; in testAHardwareBuffer_allocate_BlobFormatRequiresHeight1()
104 desc.height = 1; in testAHardwareBuffer_allocate_BlobFormatRequiresHeight1()
118 desc.height = 4; in testAHardwareBuffer_allocate_Succeeds()
129 desc.height = 12; in testAHardwareBuffer_allocate_Succeeds()
144 desc.height = 4; in testAHardwareBuffer_describe_Succeeds()
186 desc.height = 4; in testAHardwareBuffer_SendAndRecv_Succeeds()
234 desc.height = 4; in testAHardwareBuffer_Lock_and_Unlock_Succeed()
263 desc.height = 4; in testAHardwareBufferSupportsLayeredBuffersForVr()
[all …]

12345678910>>...13