Home
last modified time | relevance | path

Searched refs:bmp (Results 1 – 25 of 26) sorted by relevance

12

/cts/tests/tests/graphics/src/android/graphics/drawable/cts/
DNinePatchDrawableTest.java100 Bitmap bmp = BitmapFactory.decodeResource(mResources, R.drawable.ninepatch_0); in testConstructors() local
103 new NinePatchDrawable(bmp, chunk, r, name); in testConstructors()
105 new NinePatchDrawable(new NinePatch(bmp, chunk, name)); in testConstructors()
110 new NinePatchDrawable(bmp, chunk, r, name); in testConstructors()
119 Bitmap bmp = Bitmap.createBitmap(9, 9, Config.ARGB_8888); in testDraw() local
120 Canvas c = new Canvas(bmp); in testDraw()
126 verifyColorFillRect(bmp, 0, 0, 4, 4, Color.RED); in testDraw()
127 verifyColorFillRect(bmp, 5, 0, 4, 4, Color.BLUE); in testDraw()
128 verifyColorFillRect(bmp, 0, 5, 4, 4, ocean); in testDraw()
129 verifyColorFillRect(bmp, 5, 5, 4, 4, Color.YELLOW); in testDraw()
[all …]
DTransitionDrawableTest.java212 private void verifyColorFillRect(Bitmap bmp, int x, int y, int w, int h, int color) { in verifyColorFillRect() argument
215 assertEquals(color, bmp.getPixel(i, j)); in verifyColorFillRect()
220 private void verifyColorNotFillRect(Bitmap bmp, int x, int y, int w, int h, int color) { in verifyColorNotFillRect() argument
223 assertTrue(color != bmp.getPixel(i, j)); in verifyColorNotFillRect()
/cts/tests/wallpapereffectsgeneration/src/android/wallpapereffectsgeneration/cts/
DCinematicEffectRequestTest.java45 final Bitmap bmp = Bitmap.createBitmap(320, 480, Bitmap.Config.ARGB_8888); in testCreateCinematicEffectRequest() local
46 CinematicEffectRequest request = new CinematicEffectRequest(taskId, bmp); in testCreateCinematicEffectRequest()
50 assertThat(request.getBitmap()).isEqualTo(bmp); in testCreateCinematicEffectRequest()
60 assertThat(copy.getBitmap().sameAs(bmp)).isTrue(); in testCreateCinematicEffectRequest()
DTexturedMeshTest.java44 final Bitmap bmp = Bitmap.createBitmap(3200, 4800, Config.ARGB_8888); in testCreateTexturedMeshRequest() local
50 TexturedMesh texturedMesh = new TexturedMesh.Builder(bmp) in testCreateTexturedMeshRequest()
57 assertThat(texturedMesh.getBitmap()).isEqualTo(bmp); in testCreateTexturedMeshRequest()
71 assertThat(copy.getBitmap().sameAs(bmp)).isTrue(); in testCreateTexturedMeshRequest()
DCinematicEffectResponseTest.java52 final Bitmap bmp = Bitmap.createBitmap(3200, 4800, Config.ARGB_8888); in testCreateCinematicEffectResponse() local
58 final TexturedMesh texturedMesh = new TexturedMesh.Builder(bmp) in testCreateCinematicEffectResponse()
119 assertThat(mesh.getBitmap()).isEqualTo(bmp); in testCreateCinematicEffectResponse()
162 assertThat(meshCopy.getBitmap().sameAs(bmp)).isTrue(); in testCreateCinematicEffectResponse()
DWallpaperEffectsGenerationManagerTest.java204 Bitmap bmp = Bitmap.createBitmap(32, 48, Bitmap.Config.ARGB_8888); in createCinematicEffectRequest() local
205 return new CinematicEffectRequest(taskId, bmp); in createCinematicEffectRequest()
/cts/tests/tests/text/src/android/text/cts/
DControlCharacterGlyphTest.java37 Bitmap bmp = Bitmap.createBitmap(200, 200, Bitmap.Config.ALPHA_8); in testLineBreakDrawsNothing() local
39 Canvas canvas = new Canvas(bmp); in testLineBreakDrawsNothing()
43 assertThat(bmp.sameAs(emptyBitmap)).isTrue(); in testLineBreakDrawsNothing()
DFontVariationSettingsTest.kt45 val bmp = Bitmap.createBitmap(w, layout.height, Bitmap.Config.ALPHA_8) in drawText() constant
46 Canvas(bmp).drawText(text, 0, text.length, 0f, layout.getLineAscent(0).toFloat(), paint) in drawText()
47 return bmp in drawText()
DEmojiTest.java89 private String describeBitmap(final Bitmap bmp) { in describeBitmap() argument
91 sb.append("[ID:0x" + Integer.toHexString(System.identityHashCode(bmp))); in describeBitmap()
92 sb.append(" " + Integer.toString(bmp.getWidth()) + "x" + Integer.toString(bmp.getHeight())); in describeBitmap()
94 if (bmp.getConfig() == Bitmap.Config.ALPHA_8) { in describeBitmap()
96 } else if (bmp.getConfig() == Bitmap.Config.RGB_565) { in describeBitmap()
98 } else if (bmp.getConfig() == Bitmap.Config.ARGB_4444) { in describeBitmap()
100 } else if (bmp.getConfig() == Bitmap.Config.ARGB_8888) { in describeBitmap()
DBoringLayoutTest.java367 final Bitmap bmp = Bitmap.createBitmap(l.getWidth(), l.getHeight(), Bitmap.Config.RGB_565); in drawToBitmap() local
368 final Canvas c = new Canvas(bmp); in drawToBitmap()
374 return bmp; in drawToBitmap()
DStaticLayoutTest.java1338 final Bitmap bmp = Bitmap.createBitmap(l.getWidth(), l.getHeight(), Bitmap.Config.RGB_565);
1339 final Canvas c = new Canvas(bmp);
1345 return bmp;
1744 final Bitmap bmp = Bitmap.createBitmap(
1748 final Canvas c = new Canvas(bmp);
DPrecomputedTextTest.java697 final Bitmap bmp = Bitmap.createBitmap(rect.width(), in drawToBitmap() local
699 final Canvas c = new Canvas(bmp); in drawToBitmap()
704 return bmp; in drawToBitmap()
/cts/common/device-side/util-axt/src/com/android/compatibility/common/util/
DBitmapUtils.java126 final Bitmap bmp = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888); in generateRandomBitmap() local
130 bmp.setPixel(x, y, generator.nextInt(Integer.MAX_VALUE)); in generateRandomBitmap()
133 return bmp; in generateRandomBitmap()
137 final Bitmap bmp = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888); in generateWhiteBitmap() local
138 bmp.eraseColor(Color.WHITE); in generateWhiteBitmap()
139 return bmp; in generateWhiteBitmap()
150 public static ByteArrayInputStream bitmapToInputStream(Bitmap bmp) { in bitmapToInputStream() argument
152 bmp.compress(CompressFormat.PNG, 0 /*ignored for PNG*/, bos); in bitmapToInputStream()
/cts/tests/tests/graphics/src/android/graphics/cts/
DCanvasDrawGlyphsTest.java61 Bitmap bmp = Bitmap.createBitmap(BMP_WIDTH, BMP_HEIGHT, Bitmap.Config.ARGB_8888); in drawGlyphsToBitmap() local
62 Canvas canvas = new Canvas(bmp); in drawGlyphsToBitmap()
65 return bmp; in drawGlyphsToBitmap()
260 Bitmap bmp = drawGlyphsToBitmap( in drawGlyphs_positionDifference() local
294 assertThat(bmp.sameAs(differentGlyphPositionBmp)).isFalse(); in drawGlyphs_positionDifference()
302 Bitmap bmp = drawGlyphsToBitmap( in drawGlyphs_paintEffect() local
335 assertThat(bmp.sameAs(twiceTextSizeBmp)).isFalse(); in drawGlyphs_paintEffect()
/cts/tests/openglperf2/src/android/opengl2/cts/reference/
DGLGameActivity.java156 Bitmap bmp = BitmapFactory.decodeStream(in, null, op); in loadTexture() local
170 GLUtils.texImage2D(GLES20.GL_TEXTURE_2D, 0, bmp, 0); in loadTexture()
178 bmp.recycle(); in loadTexture()
/cts/tests/app/WallpaperTest/src/android/app/cts/wallpapers/
DWallpaperColorsTest.java83 Bitmap bmp = Bitmap.createBitmap(30, 30, Bitmap.Config.ARGB_8888); in fromBitmapTest() local
84 Canvas canvas = new Canvas(bmp); in fromBitmapTest()
87 WallpaperColors colors = WallpaperColors.fromBitmap(bmp); in fromBitmapTest()
DWallpaperManagerTest.java1741 Bitmap bmp = Bitmap.createBitmap(100, 100, Bitmap.Config.ARGB_8888); in ensureCleanState() local
1742 Canvas canvas = new Canvas(bmp); in ensureCleanState()
1748 mWallpaperManager.setBitmap(bmp); in ensureCleanState()
1750 mWallpaperManager.setBitmap(bmp, /* visibleCropHint= */ in ensureCleanState()
1757 bmp.recycle(); in ensureCleanState()
/cts/tests/mediapc/src/android/mediapc/cts/
DTextureRender.java288 Bitmap bmp = Bitmap.createBitmap(colors, width, height, Bitmap.Config.ARGB_8888); in saveFrame() local
289 bmp.compress(Bitmap.CompressFormat.PNG, 90, fos); in saveFrame()
290 bmp.recycle(); in saveFrame()
/cts/apps/CtsVerifier/src/com/android/cts/verifier/sensors/
DCtsMediaTextureRender.java292 Bitmap bmp = Bitmap.createBitmap(colors, width, height, Bitmap.Config.ARGB_8888); in saveFrame() local
293 bmp.compress(Bitmap.CompressFormat.PNG, 90, fos); in saveFrame()
294 bmp.recycle(); in saveFrame()
/cts/tests/tests/media/common/src/android/media/cts/
DTextureRender.java299 Bitmap bmp = Bitmap.createBitmap(colors, width, height, Bitmap.Config.ARGB_8888); in saveFrame() local
300 bmp.compress(Bitmap.CompressFormat.PNG, 90, fos); in saveFrame()
301 bmp.recycle(); in saveFrame()
/cts/tests/media/common/src/android/mediav2/common/cts/
DTextureRender.java322 Bitmap bmp = Bitmap.createBitmap(colors, width, height, Bitmap.Config.ARGB_8888); in saveFrame() local
323 bmp.compress(Bitmap.CompressFormat.PNG, 90, fos); in saveFrame()
324 bmp.recycle(); in saveFrame()
/cts/tests/tests/widget/src/android/widget/cts/
DTextViewSearchResultHighlightTest.java91 Bitmap bmp = Bitmap.createBitmap(r.width(), r.height(), Bitmap.Config.ARGB_8888); in drawToBitmap() local
92 Canvas c = new Canvas(bmp); in drawToBitmap()
94 return bmp; in drawToBitmap()
DTextViewHighlightTest.java92 Bitmap bmp = Bitmap.createBitmap(r.width(), r.height(), Bitmap.Config.ARGB_8888); in drawToBitmap() local
93 Canvas c = new Canvas(bmp); in drawToBitmap()
95 return bmp; in drawToBitmap()
/cts/tests/tests/security/src/android/security/cts/
DBinderExploitTest.java170 Bitmap bmp = Bitmap.createBitmap(1, 1, Bitmap.Config.ALPHA_8); in setUpBundle() local
171 if (actmgr.addAppTask(this, in, null, bmp) == -1) in setUpBundle()
/cts/tests/tests/opengl/src/android/opengl/cts/
DFramebufferTest.java619 Bitmap bmp = Bitmap.createBitmap(colors, mWidth, mHeight, Bitmap.Config.ARGB_8888); in saveFrame() local
620 bmp.compress(Bitmap.CompressFormat.PNG, 90, bos); in saveFrame()
621 bmp.recycle(); in saveFrame()

12