| /packages/apps/Gallery2/src/com/android/gallery3d/data/ |
| ImageCacheRequest.java | 19 import android.graphics.Bitmap; 28 abstract class ImageCacheRequest implements Job<Bitmap> { 53 public Bitmap run(JobContext jc) { 62 options.inPreferredConfig = Bitmap.Config.ARGB_8888; 63 Bitmap bitmap; local 65 bitmap = DecodeUtils.decodeUsingPool(jc, 68 bitmap = DecodeUtils.decodeUsingPool(jc, 71 if (bitmap == null && !jc.isCancelled()) { 74 return bitmap; 79 Bitmap bitmap = onDecodeOriginal(jc, mType); local [all...] |
| /packages/apps/Gallery2/src/com/android/gallery3d/filtershow/filters/ |
| IconUtilities.java | 20 import android.graphics.Bitmap; 36 public static Bitmap getFXBitmap(Resources res, int id) { 37 Bitmap ret; 47 public static Bitmap loadBitmap(Resources res, int resource) { 50 options.inPreferredConfig = Bitmap.Config.ARGB_8888; 51 Bitmap bitmap = BitmapFactory.decodeResource( local 55 return bitmap; 58 public static Bitmap applyFX(Bitmap bitmap, final Bitmap fxBitmap) [all...] |
| ImageFilterDownsample.java | 19 import android.graphics.Bitmap; 53 public Bitmap apply(Bitmap bitmap, float scaleFactor, int quality) { 55 return bitmap; 57 int w = bitmap.getWidth(); 58 int h = bitmap.getHeight(); 67 // scale preview to same size as the resulting bitmap from a "save" 73 return bitmap; 75 Bitmap ret = Bitmap.createScaledBitmap(bitmap, newWidth, newHeight, true) [all...] |
| /packages/apps/Gallery2/src/com/android/gallery3d/gadget/ |
| WidgetUtils.java | 21 import android.graphics.Bitmap; 22 import android.graphics.Bitmap.Config; 47 public static Bitmap createWidgetBitmap(MediaItem image) { 48 Bitmap bitmap = image.requestImage(MediaItem.TYPE_THUMBNAIL) local 50 if (bitmap == null) { 54 return createWidgetBitmap(bitmap, image.getRotation()); 57 public static Bitmap createWidgetBitmap(Bitmap bitmap, int rotation) [all...] |
| /packages/apps/Messaging/src/com/android/messaging/datamodel/media/ |
| NetworkUriImageRequest.java | 19 import android.graphics.Bitmap; 83 public Bitmap loadBitmapInternal() throws IOException { 87 Bitmap bitmap = null; local 95 bitmap = BitmapFactory.decodeStream(connection.getInputStream()); 118 return bitmap;
|
| /packages/apps/UnifiedEmail/src/com/android/mail/bitmap/ |
| ContactRequest.java | 16 package com.android.mail.bitmap; 20 import com.android.bitmap.RequestKey; 21 import com.android.mail.bitmap.ContactResolver.ContactDrawableInterface;
|
| /cts/apps/CtsVerifier/src/com/android/cts/verifier/sensors/renderers/ |
| GLArrowSensorTestRenderer.java | 22 import android.graphics.Bitmap; 138 Bitmap bitmap; local 140 bitmap = BitmapFactory.decodeStream(is); 149 GLUtils.texImage2D(GL10.GL_TEXTURE_2D, 0, bitmap, 0); 150 bitmap.recycle();
|
| /cts/tests/tests/uirendering/src/android/uirendering/cts/testclasses/ |
| BitmapFilterTests.java | 18 import android.graphics.Bitmap; 41 // Creates Paint object that will have bitmap filtering 43 // First uses a Paint object with bitmap filtering, then uses canvas.setDrawFilter to remove 44 // the bitmap filtering 68 private static Bitmap createGridBitmap(int width, int height) { 69 Bitmap bitmap = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888); local 73 bitmap.setPixel(i, j, isWhite ? Color.WHITE : Color.BLACK) [all...] |
| /cts/tests/tests/view/src/android/view/cts/ |
| SurfaceViewSyncTest.java | 24 import android.graphics.Bitmap; 194 private void saveFailureCaptures(SparseArray<Bitmap> failFrames) { 215 Bitmap bitmap = failFrames.valueAt(i); local 222 bitmap.compress(Bitmap.CompressFormat.PNG, 85, fileStream);
|
| TextureViewCameraActivity.java | 20 import android.graphics.Bitmap; 101 Bitmap bitmap = mTextureView.getBitmap(); local 102 Log.d(TAG, "acquired bitmap"); 103 Assert.assertEquals(mHeight, bitmap.getHeight()); 104 Assert.assertEquals(mWidth, bitmap.getWidth()); 105 bitmap.recycle();
|
| /development/samples/ApiDemos/src/com/example/android/apis/graphics/ |
| StaticTriangleRenderer.java | 32 import android.graphics.Bitmap; 191 Bitmap bitmap; local 193 bitmap = BitmapFactory.decodeStream(is); 202 GLUtils.texImage2D(GL_TEXTURE_2D, 0, bitmap, 0); 203 bitmap.recycle();
|
| TriangleRenderer.java | 30 import android.graphics.Bitmap; 93 Bitmap bitmap; local 95 bitmap = BitmapFactory.decodeStream(is); 104 GLUtils.texImage2D(GL10.GL_TEXTURE_2D, 0, bitmap, 0); 105 bitmap.recycle();
|
| /external/glide/library/src/main/java/com/bumptech/glide/load/resource/bitmap/ |
| GlideBitmapDrawable.java | 1 package com.bumptech.glide.load.resource.bitmap; 4 import android.graphics.Bitmap; 27 public GlideBitmapDrawable(Resources res, Bitmap bitmap) { 28 this(res, new BitmapState(bitmap)); 45 width = state.bitmap.getScaledWidth(targetDensity); 46 height = state.bitmap.getScaledHeight(targetDensity); 101 canvas.drawBitmap(state.bitmap, null, destRect, state.paint); 121 Bitmap bm = state.bitmap; 144 final Bitmap bitmap; field in class:GlideBitmapDrawable.BitmapState [all...] |
| /external/replicaisland/src/com/replica/replicaisland/ |
| SpriteComponent.java | 108 // Fire and forget. Allocate a new bitmap for this animation frame, set it up, and 110 DrawableBitmap bitmap = factory.allocateDrawableBitmap(); local 111 bitmap.setWidth(mWidth); 112 bitmap.setHeight(mHeight); 113 bitmap.setOpacity(mOpacity); 114 updateFlip(bitmap, parentObject.facingDirection.x < 0.0f, 116 bitmap.setTexture(currentFrame.texture); 117 render.setDrawable(bitmap); 182 protected final void updateFlip(DrawableBitmap bitmap, boolean horzFlip, boolean vertFlip) { 183 bitmap.setFlip(horzFlip, vertFlip) [all...] |
| TextureLibrary.java | 27 import android.graphics.Bitmap; 58 sBitmapOptions.inPreferredConfig = Bitmap.Config.RGB_565; 126 /** Loads a bitmap into OpenGL and sets up the common parameters for 2D texture maps. */ 161 Bitmap bitmap; local 163 bitmap = BitmapFactory.decodeStream(is); 173 GLUtils.texImage2D(GL10.GL_TEXTURE_2D, 0, bitmap, 0); 183 mCropWorkspace[1] = bitmap.getHeight(); 184 mCropWorkspace[2] = bitmap.getWidth(); 185 mCropWorkspace[3] = -bitmap.getHeight() [all...] |
| /external/robolectric-shadows/robolectric/src/test/java/org/robolectric/shadows/ |
| ShadowBitmapFactoryTest.java | 8 import android.graphics.Bitmap; 27 Bitmap bitmap = BitmapFactory.decodeResource(RuntimeEnvironment.application.getResources(), R.drawable.an_image); local 28 ShadowBitmap shadowBitmap = shadowOf(bitmap); 29 assertEquals("Bitmap for resource:org.robolectric:drawable/an_image", shadowBitmap.getDescription()); 31 assertEquals(100, bitmap.getWidth()); 32 assertEquals(100, bitmap.getHeight()); 37 Bitmap bitmap = BitmapFactory.decodeResource(RuntimeEnvironment.application.getResources(), R.drawable.an_image); local 38 assertThat(bitmap.getConfig()).isEqualTo(Bitmap.Config.ARGB_8888) 51 Bitmap bitmap = BitmapFactory.decodeResource(RuntimeEnvironment.application.getResources(), R.drawable.an_image, options); local 57 Bitmap bitmap = BitmapFactory.decodeFile("\/some\/file.jpg"); local 68 Bitmap bitmap = BitmapFactory.decodeStream(inputStream); local 80 Bitmap bitmap = BitmapFactory.decodeByteArray(yummyBites, 100, 100); local 91 Bitmap bitmap = BitmapFactory.decodeStream(inputStream, null, null); local 101 Bitmap bitmap = BitmapFactory.decodeResource(RuntimeEnvironment.application.getResources(), R.drawable.an_image); local 111 Bitmap bitmap = BitmapFactory.decodeResource(RuntimeEnvironment.application.getResources(), R.drawable.an_image, options); local 120 Bitmap bitmap = BitmapFactory.decodeResourceStream(RuntimeEnvironment.application.getResources(), null, inputStream, null, options); local 128 Bitmap bitmap = BitmapFactory.decodeFile("\/some\/file.jpg"); local 148 Bitmap bitmap = MediaStore.Images.Media.getBitmap(RuntimeEnvironment.application.getContentResolver(), Uri.parse("content:\/path")); local 164 Bitmap bitmap = BitmapFactory.decodeFileDescriptor(fd); local 182 Bitmap bitmap = BitmapFactory.decodeByteArray(bytes, 0, bytes.length); local 194 Bitmap bitmap = BitmapFactory.decodeByteArray(bytes, 1, bytes.length - 2); local 203 Bitmap bitmap = BitmapFactory.decodeStream(inputStream); local 212 Bitmap bitmap = BitmapFactory.decodeStream(inputStream); local 222 Bitmap bitmap = ShadowBitmapFactory.decodeByteArray(data, 0, data.length); local 235 Bitmap bitmap = ShadowBitmapFactory.decodeByteArray(data, 0, data.length - 1, options); local 266 final Bitmap bitmap = ShadowBitmapFactory.create("file:image.png", null, new Point(50, 60)); local 274 final Bitmap bitmap = ShadowBitmapFactory.create(null, null, new Point(70, 80)); local 282 final Bitmap bitmap = ShadowBitmapFactory.create(null, null, null); local [all...] |
| /external/webrtc/webrtc/modules/video_render/android/java/src/org/webrtc/videoengine/ |
| ViESurfaceRenderer.java | 21 import android.graphics.Bitmap; 34 // the bitmap used for drawing. 35 private Bitmap bitmap = null; field in class:ViESurfaceRenderer 38 // Rect of the source bitmap to draw 104 bitmap = null; 108 public Bitmap CreateBitmap(int width, int height) { 110 if (bitmap == null) { 118 bitmap = Bitmap.createBitmap(width, height, Bitmap.Config.RGB_565) [all...] |
| /frameworks/base/tests/UiBench/src/com/android/test/uibench/leanback/ |
| BitmapLoader.java | 19 import android.graphics.Bitmap; 29 * This class simulates a typical Bitmap memory cache with up to 1.5 times of screen pixels. 30 * The sample bitmap is generated in worker threads in AsyncTask.THREAD_POOL_EXECUTOR. 34 * 1. As a typical app, each card has its own id and load its own Bitmap, the test result will 36 * 2. All cards share same id/Bitmap and there wont be texture upload. 50 static LruCache<Long, Bitmap> sLruCache; 60 static LruCache<Long, Bitmap> getLruCache(Context context) { 66 sLruCache = new LruCache<Long, Bitmap>(maxBytes) { 68 protected int sizeOf(Long key, Bitmap value) { 76 static class BitmapAsyncTask extends AsyncTask<Void, Void, Bitmap> { 94 Bitmap bitmap = Bitmap.createBitmap(mWidth, mHeight, Bitmap.Config.ARGB_8888); local 122 Bitmap bitmap = getLruCache(context).get(id); local [all...] |
| /frameworks/opt/bitmap/src/com/android/bitmap/drawable/ |
| CircularBitmapDrawable.java | 17 package com.android.bitmap.drawable; 20 import android.graphics.Bitmap; 32 import com.android.bitmap.BitmapCache; 46 private Bitmap mShaderBitmap; 105 Bitmap bitmap = placeholder.getBitmap(); local 107 mRect.set(0, 0, bitmap.getWidth(), bitmap.getHeight()); 108 onDrawCircularBitmap(bitmap, canvas, mRect, bounds, alpha); 119 * Call this method with a given bitmap to draw it onto the given canvas, masked by a circula [all...] |
| /frameworks/support/samples/SupportLeanbackJank/src/main/java/com/google/android/leanbackjank/data/ |
| VideoProvider.java | 20 import android.graphics.Bitmap; 21 import android.graphics.Bitmap.CompressFormat; 107 Bitmap bitmap = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888); local 108 Canvas canvas = new Canvas(bitmap); 136 bitmap.compress(CompressFormat.JPEG, 90, outputStream);
|
| /frameworks/support/slices/view/src/main/java/androidx/slice/widget/ |
| SliceViewUtil.java | 22 import android.graphics.Bitmap; 23 import android.graphics.Bitmap.Config; 145 Bitmap b = Bitmap.createBitmap(d.getIntrinsicWidth(), d.getIntrinsicHeight(), 146 Bitmap.Config.ARGB_8888); 164 // XXX better way to convert from icon -> bitmap or crop an icon (?) 165 Bitmap iconBm = Bitmap.createBitmap(iconSizePx, iconSizePx, Config.ARGB_8888); 180 public static @NonNull Bitmap getCircularBitmap(Bitmap bitmap) [all...] |
| /frameworks/support/textclassifier/src/androidTest/java/androidx/textclassifier/ |
| TextClassificationTest.java | 22 import android.graphics.Bitmap; 49 final Bitmap bitmap = Bitmap.createBitmap(colors, width, height, Bitmap.Config.ARGB_8888); local 50 final BitmapDrawable drawable = new BitmapDrawable(null, bitmap); 51 drawable.setTargetDensity(bitmap.getDensity()); 98 final Bitmap resPrimaryIcon = ((BitmapDrawable) result.getIcon()).getBitmap(); 106 final Bitmap resSecondaryIcon0 = ((BitmapDrawable) result.getSecondaryIcon(0)).getBitmap(); 114 final Bitmap resSecondaryIcon1 = ((BitmapDrawable) result.getSecondaryIcon(1)).getBitmap() [all...] |
| /packages/apps/Dialer/java/com/android/dialer/callcomposer/camera/ |
| ImagePersistWorker.java | 21 import android.graphics.Bitmap; 122 Bitmap bitmap = BitmapFactory.decodeByteArray(bytes, 0, bytes.length); local 126 Assert.checkState(width == bitmap.getHeight()); 127 Assert.checkState(height == bitmap.getWidth()); 131 Assert.checkState(width == bitmap.getWidth()); 132 Assert.checkState(height == bitmap.getHeight()); 137 int offsetTop = (bitmap.getHeight() - clippedHeight) / 2; 138 int offsetLeft = (bitmap.getWidth() - clippedWidth) / 2; 142 Bitmap clippedBitmap [all...] |
| /packages/apps/Dialer/java/com/android/dialer/databasepopulator/ |
| ContactsPopulator.java | 22 import android.graphics.Bitmap; 341 Bitmap bitmap = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888); local 342 Canvas canvas = new Canvas(bitmap); 350 bitmap.compress(Bitmap.CompressFormat.PNG, 75, photoStream);
|
| /packages/apps/Gallery/src/com/android/camera/ |
| PhotoAppWidgetProvider.java | 29 import android.graphics.Bitmap; 77 Bitmap bitmap = helper.getPhoto(appWidgetId); local 78 if (bitmap != null) { 81 views.setImageViewBitmap(R.id.photo, bitmap); 120 * Store the given bitmap in this database for the given appWidgetId. 122 public boolean setPhoto(int appWidgetId, Bitmap bitmap) { 128 int size = bitmap.getWidth() * bitmap.getHeight() * 4 166 Bitmap bitmap = null; local [all...] |