Home
last modified time | relevance | path

Searched refs:mBitmap (Results 1 – 16 of 16) sorted by relevance

/cts/tests/tests/graphics/src/android/graphics/cts/
DBitmapTest.java75 private Bitmap mBitmap; field in BitmapTest
83 mBitmap = BitmapFactory.decodeResource(mRes, R.drawable.start, mOptions); in setup()
88 mBitmap.recycle(); in testCompressRecycled()
89 mBitmap.compress(CompressFormat.JPEG, 0, null); in testCompressRecycled()
94 mBitmap.compress(CompressFormat.JPEG, 0, null); in testCompressNullStream()
99 mBitmap.compress(CompressFormat.JPEG, -1, new ByteArrayOutputStream()); in testCompressQualityTooLow()
104 mBitmap.compress(CompressFormat.JPEG, 101, new ByteArrayOutputStream()); in testCompressQualityTooHigh()
109 assertTrue(mBitmap.compress(CompressFormat.JPEG, 50, new ByteArrayOutputStream())); in testCompress()
114 mBitmap.recycle(); in testCopyRecycled()
115 mBitmap.copy(Config.RGB_565, false); in testCopyRecycled()
[all …]
DNinePatchTest.java53 private Bitmap mBitmap; field in NinePatchTest
63 mBitmap = BitmapFactory.decodeResource(mRes, R.drawable.opaque, mOptNoScale); in setup()
64 mChunk = mBitmap.getNinePatchChunk(); in setup()
66 mNinePatch = new NinePatch(mBitmap, mChunk, NAME); in setup()
71 mNinePatch = new NinePatch(mBitmap, new byte[2]); in testConstructorTooShort()
76 mNinePatch = new NinePatch(mBitmap, new byte[2], NAME); in testConstructorNamedTooShort()
81 mNinePatch = new NinePatch(mBitmap, mChunk); in testConstructor()
82 assertEquals(mBitmap, mNinePatch.getBitmap()); in testConstructor()
85 mNinePatch = new NinePatch(mBitmap, mChunk, NAME); in testConstructor()
86 assertEquals(mBitmap, mNinePatch.getBitmap()); in testConstructor()
[all …]
DSweepGradientTest.java51 private Bitmap mBitmap; field in SweepGradientTest
56 mBitmap = Bitmap.createBitmap(SIZE, SIZE, Config.ARGB_8888); in setup()
57 mBitmap.eraseColor(Color.TRANSPARENT); in setup()
58 mCanvas = new Canvas(mBitmap); in setup()
133 int pixel = mBitmap.getPixel(x, y); in verifyColors()
/cts/tests/tests/uirendering/src/android/uirendering/cts/testclasses/view/
DBitmapView.java28 private Bitmap mBitmap; field in BitmapView
45 mBitmap = b; in BitmapView()
50 return mBitmap; in getBitmap()
54 mBitmap = bitmap; in setBitmap()
71 canvas.drawBitmap(mBitmap, 0, 0, null); in onDraw()
79 setMeasuredDimension(mBitmap.getWidth(), mBitmap.getHeight()); in onMeasure()
/cts/tests/tests/graphics/src/android/graphics/drawable/cts/
DTransitionDrawableTest.java59 private Bitmap mBitmap; field in TransitionDrawableTest
68 mBitmap = Bitmap.createBitmap(CANVAS_WIDTH, CANVAS_HEIGHT, Config.ARGB_8888); in setup()
69 mCanvas = new Canvas(mBitmap); in setup()
156 int colorFrom = mBitmap.getPixel(0, 0); in testReverseTransition()
164 colorFrom = mBitmap.getPixel(0, 0); in testReverseTransition()
195 mBitmap.eraseColor(Color.TRANSPARENT); in verifyTransitionStart()
197 verifyColorFillRect(mBitmap, 0, 0, CANVAS_WIDTH, CANVAS_HEIGHT, colorFrom); in verifyTransitionStart()
202 verifyColorNotFillRect(mBitmap, 0, 0, CANVAS_WIDTH, CANVAS_HEIGHT, colorFrom); in verifyTransitionInProgress()
203 verifyColorNotFillRect(mBitmap, 0, 0, CANVAS_WIDTH, CANVAS_HEIGHT, colorTo); in verifyTransitionInProgress()
208 verifyColorFillRect(mBitmap, 0, 0, CANVAS_WIDTH, CANVAS_HEIGHT, colorTo); in verifyTransitionEnd()
[all …]
DVectorDrawableTest.java192 private Bitmap mBitmap; field in VectorDrawableTest
201 mBitmap = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888); in setup()
202 mCanvas = new Canvas(mBitmap); in setup()
263 mBitmap.eraseColor(0); in verifyVectorDrawables()
268 DrawableTestUtils.saveAutoNamedVectorDrawableIntoPNG(mContext, mBitmap, resIds[i], in verifyVectorDrawables()
273 DrawableTestUtils.compareImages(mResources.getString(resIds[i]), mBitmap, golden, in verifyVectorDrawables() local
/cts/hostsidetests/theme/app/src/android/theme/app/
DGenerateBitmapTask.java40 private Bitmap mBitmap; field in GenerateBitmapTask
57 mBitmap = Bitmap.createBitmap(mView.getWidth(), mView.getHeight(), in onPreExecute()
60 final Canvas canvas = new Canvas(mBitmap); in onPreExecute()
66 final Bitmap bitmap = mBitmap; in doInBackground()
/cts/tests/tests/uirendering/src/android/uirendering/cts/testclasses/
DWideColorGamutTests.java63 private Bitmap mBitmap; field in WideColorGamutTests
73 mBitmap = BitmapFactory.decodeStream(in); in loadBitmap()
94 bv.setBitmap(mBitmap); in testDraw()
104 bv.setBitmap(mBitmap); in testSaveLayer()
115 bv.setBitmap(mBitmap); in testHardwareLayer()
126 bv.setBitmap(mBitmap); in testSaveLayerInHardwareLayer()
DShaderTests.java107 Bitmap mBitmap; in testComplexShaderUsage()
111 if (mBitmap == null) { in testComplexShaderUsage()
112 mBitmap = Bitmap.createBitmap(width, height, Bitmap.Config.ALPHA_8); in testComplexShaderUsage()
114 Canvas bitmapCanvas = new Canvas(mBitmap); in testComplexShaderUsage()
136 canvas.drawBitmap(mBitmap, 0, 0, mPaint); in testComplexShaderUsage()
DBitmapTests.java56 private Bitmap mBitmap; field in BitmapTests.BitmapView
61 mBitmap = Bitmap.createBitmap(1, 1, Bitmap.Config.ARGB_8888); in BitmapView()
67 canvas.drawBitmap(mBitmap, new Rect(0, 0, 1, 1), canvas.getClipBounds(), null); in onDraw()
72 mBitmap.setPixel(0, 0, color); in setColor()
DColorFilterAlphaTest.java139 private final Bitmap mBitmap = createMultiRectBitmap();
146 canvas.drawBitmap(mBitmap, 0, 0, mPaint);
DSweepTests.java49 private final Bitmap mBitmap = createGradient();
53 canvas.drawBitmap(mBitmap, 0, 0, paint);
/cts/tests/tests/renderscript/src/android/renderscript/cts/refocus/f32/
DRefocusFilterF32.java98 Bitmap mBitmap = Bitmap.createBitmap(buffers.inputImage.getWidth(), in extractSharpImage() local
100 Allocation mAllocation = Allocation.createFromBitmap(renderScript, mBitmap); in extractSharpImage()
103 mAllocation.copyTo(mBitmap); in extractSharpImage()
105 MediaStoreSaver.savePNG(mBitmap, "sharpF32", name, renderScript.getApplicationContext()); in extractSharpImage()
113 Bitmap mBitmap = Bitmap.createBitmap(buffers.inputImage.getWidth(), in extractFuzzyImage() local
115 Allocation mAllocation = Allocation.createFromBitmap(renderScript, mBitmap); in extractFuzzyImage()
118 mAllocation.copyTo(mBitmap); in extractFuzzyImage()
120 MediaStoreSaver.savePNG(mBitmap, "fuzzyF32", name, renderScript.getApplicationContext()); in extractFuzzyImage()
/cts/tests/tests/renderscript/src/android/renderscript/cts/refocus/d1new/
DRefocusFilterd1new.java98 Bitmap mBitmap = Bitmap.createBitmap(buffers.inputImage.getWidth(), in extractSharpImage() local
100 Allocation mAllocation = Allocation.createFromBitmap(renderScript, mBitmap); in extractSharpImage()
103 mAllocation.copyTo(mBitmap); in extractSharpImage()
105 MediaStoreSaver.savePNG(mBitmap, "sharpd1new", name, renderScript.getApplicationContext()); in extractSharpImage()
112 Bitmap mBitmap = Bitmap.createBitmap(buffers.inputImage.getWidth(), in extractFuzzyImage() local
114 Allocation mAllocation = Allocation.createFromBitmap(renderScript, mBitmap); in extractFuzzyImage()
117 mAllocation.copyTo(mBitmap); in extractFuzzyImage()
119 MediaStoreSaver.savePNG(mBitmap, "fuzzyd1new", name, renderScript.getApplicationContext()); in extractFuzzyImage()
/cts/tests/tests/view/src/android/view/cts/
DPixelCopyWideGamutViewProducerActivity.java123 private final Bitmap mBitmap; field in PixelCopyWideGamutViewProducerActivity.WideGamutBitmapView
130 mBitmap = BitmapFactory.decodeStream(in); in WideGamutBitmapView()
138 canvas.drawBitmap(mBitmap, 0.0f, 0.0f, null); in onDraw()
/cts/tests/tests/openglperf/src/android/openglperf/cts/
DTextureTestRenderer.java59 private final Bitmap mBitmap; field in TextureTestRenderer
77 mBitmap = Bitmap.createBitmap(colors, 4, 4, Bitmap.Config.ARGB_8888); in TextureTestRenderer()
173 GLUtils.texImage2D(GL10.GL_TEXTURE_2D, 0, mBitmap, 0); in onSurfaceCreated()