/frameworks/base/opengl/java/android/opengl/ |
H A D | GLUtils.java | 36 * return the internal format as defined by OpenGL ES of the supplied bitmap. 37 * @param bitmap 38 * @return the internal format of the bitmap. 40 public static int getInternalFormat(Bitmap bitmap) { argument 41 if (bitmap == null) { 44 if (bitmap.isRecycled()) { 45 throw new IllegalArgumentException("bitmap is recycled"); 47 int result = native_getInternalFormat(bitmap); 55 * Return the type as defined by OpenGL ES of the supplied bitmap, if there 56 * is one. If the bitmap i 62 getType(Bitmap bitmap) argument 98 texImage2D(int target, int level, int internalformat, Bitmap bitmap, int border) argument 124 texImage2D(int target, int level, int internalformat, Bitmap bitmap, int type, int border) argument 146 texImage2D(int target, int level, Bitmap bitmap, int border) argument 181 texSubImage2D(int target, int level, int xoffset, int yoffset, Bitmap bitmap) argument 206 texSubImage2D(int target, int level, int xoffset, int yoffset, Bitmap bitmap, int format, int type) argument 264 native_getInternalFormat(Bitmap bitmap) argument 265 native_getType(Bitmap bitmap) argument 266 native_texImage2D(int target, int level, int internalformat, Bitmap bitmap, int type, int border) argument 268 native_texSubImage2D(int target, int level, int xoffset, int yoffset, Bitmap bitmap, int format, int type) argument [all...] |
/frameworks/base/packages/PrintSpooler/src/com/android/printspooler/util/ |
H A D | BitmapSerializeUtils.java | 24 * use case of having the same bitmap on both ends and just 38 * Reads a bitmap pixels from a file descriptor. 40 * @param bitmap A bitmap whose pixels to populate. 43 public static void readBitmapPixels(Bitmap bitmap, ParcelFileDescriptor source) { argument 44 nativeReadBitmapPixels(bitmap, source.getFd()); 48 * Writes a bitmap pixels to a file descriptor. 50 * @param bitmap The bitmap. 53 public static void writeBitmapPixels(Bitmap bitmap, ParcelFileDescripto argument 57 nativeReadBitmapPixels(Bitmap bitmap, int fd) argument 59 nativeWriteBitmapPixels(Bitmap bitmap, int fd) argument [all...] |
/frameworks/opt/bitmap/src/com/android/bitmap/ |
H A D | Poolable.java | 17 package com.android.bitmap;
|
H A D | BitmapCache.java | 17 package com.android.bitmap;
|
H A D | DecodeAggregator.java | 17 package com.android.bitmap;
|
/frameworks/support/compat/java/android/support/v4/graphics/ |
H A D | BitmapCompat.java | 28 public boolean hasMipMap(Bitmap bitmap) { argument 32 public void setHasMipMap(Bitmap bitmap, boolean hasMipMap) { argument 35 public int getAllocationByteCount(Bitmap bitmap) { argument 36 return bitmap.getByteCount(); 43 public boolean hasMipMap(Bitmap bitmap){ argument 44 return bitmap.hasMipMap(); 48 public void setHasMipMap(Bitmap bitmap, boolean hasMipMap) { argument 49 bitmap.setHasMipMap(hasMipMap); 56 public int getAllocationByteCount(Bitmap bitmap) { argument 57 return bitmap 75 hasMipMap(Bitmap bitmap) argument 79 setHasMipMap(Bitmap bitmap, boolean hasMipMap) argument 90 getAllocationByteCount(Bitmap bitmap) argument [all...] |
/frameworks/base/packages/WallpaperCropper/src/com/android/gallery3d/glrenderer/ |
H A D | BitmapTexture.java | 31 public BitmapTexture(Bitmap bitmap) { argument 32 this(bitmap, false); 35 public BitmapTexture(Bitmap bitmap, boolean hasBorder) { argument 37 Utils.assertTrue(bitmap != null && !bitmap.isRecycled()); 38 mContentBitmap = bitmap; 42 protected void onFreeBitmap(Bitmap bitmap) { argument
|
/frameworks/base/libs/hwui/ |
H A D | TextureCache.cpp | 95 bool TextureCache::canMakeTextureFromBitmap(Bitmap* bitmap) { argument 96 if (bitmap->width() > mMaxTextureSize || bitmap->height() > mMaxTextureSize) { 98 bitmap->width(), bitmap->height(), mMaxTextureSize, mMaxTextureSize); 104 Texture* TextureCache::createTexture(Bitmap* bitmap) { argument 106 texture->bitmapSize = bitmap->rowBytes() * bitmap->height(); 107 texture->generation = bitmap->getGenerationID(); 108 texture->upload(*bitmap); 114 getCachedTexture(Bitmap* bitmap) argument 168 prefetchAndMarkInUse(void* ownerToken, Bitmap* bitmap) argument 176 prefetch(Bitmap* bitmap) argument 180 get(Bitmap* bitmap) argument [all...] |
H A D | OpenGLReadback.h | 30 SkBitmap* bitmap) override; 32 SkBitmap* bitmap) override; 39 int imgWidth, int imgHeight, const Rect& srcRect, SkBitmap* bitmap) = 0; 42 const Rect& srcRect, SkBitmap* bitmap); 50 * Copies the layer's contents into the provided bitmap. 53 SkBitmap* bitmap); 57 int imgWidth, int imgHeight, const Rect& srcRect, SkBitmap* bitmap) override;
|
H A D | TextureCache.h | 78 * acquired for the bitmap, false otherwise. If a Texture was acquired it is 81 bool prefetchAndMarkInUse(void* ownerToken, Bitmap* bitmap); 85 * acquired for the bitmap, false otherwise. Does not mark the Texture 88 bool prefetch(Bitmap* bitmap); 91 * Returns the texture associated with the specified bitmap from within the cache. 94 Texture* get(Bitmap* bitmap); 123 bool canMakeTextureFromBitmap(Bitmap* bitmap); 125 Texture* getCachedTexture(Bitmap* bitmap); 126 Texture* createTexture(Bitmap* bitmap);
|
/frameworks/base/graphics/java/android/graphics/ |
H A D | BitmapShader.java | 22 * Shader used to draw a bitmap as a texture. The bitmap can be repeated or 37 * Call this to create a new shader that will draw with a bitmap. 39 * @param bitmap The bitmap to use inside the shader 40 * @param tileX The tiling mode for x to draw the bitmap in. 41 * @param tileY The tiling mode for y to draw the bitmap in. 43 public BitmapShader(@NonNull Bitmap bitmap, @NonNull TileMode tileX, @NonNull TileMode tileY) { argument 44 this(bitmap, tileX.nativeInt, tileY.nativeInt); 47 private BitmapShader(Bitmap bitmap, in argument 74 nativeCreate(long nativeMatrix, Bitmap bitmap, int shaderTileModeX, int shaderTileModeY) argument [all...] |
/frameworks/base/packages/WallpaperCropper/src/com/android/gallery3d/common/ |
H A D | BitmapUtils.java | 43 * bitmap. 51 * generates a smaller bitmap, unless minSideLength = UNCONSTRAINED. 116 Bitmap bitmap, float scale, boolean recycle) { 117 int width = Math.round(bitmap.getWidth() * scale); 118 int height = Math.round(bitmap.getHeight() * scale); 119 if (width == bitmap.getWidth() 120 && height == bitmap.getHeight()) return bitmap; 121 Bitmap target = Bitmap.createBitmap(width, height, getConfig(bitmap)); 125 canvas.drawBitmap(bitmap, 115 resizeBitmapByScale( Bitmap bitmap, float scale, boolean recycle) argument 130 getConfig(Bitmap bitmap) argument 138 resizeDownBySideLength( Bitmap bitmap, int maxLength, boolean recycle) argument 148 resizeAndCropCenter(Bitmap bitmap, int size, boolean recycle) argument 169 recycleSilently(Bitmap bitmap) argument 237 compressToBytes(Bitmap bitmap) argument 241 compressToBytes(Bitmap bitmap, int quality) argument [all...] |
/frameworks/opt/bitmap/src/com/android/bitmap/drawable/ |
H A D | Parallaxable.java | 17 package com.android.bitmap.drawable;
|
/frameworks/base/tests/Camera2Tests/SmartCamera/SimpleCamera/tests/src/androidx/media/filterfw/samples/simplecamera/ |
H A D | FaceSquareFilterTest.java | 62 Bitmap bitmap = BitmapFactory.decodeStream(assetMgr.open("XZZ019.jpg")); 63 image.setBitmap(bitmap); 79 int[] pixels = new int[bitmap.getByteCount()]; 80 bitmap.getPixels(pixels, 0, bitmap.getWidth(), 0, 0, bitmap.getWidth(), 81 bitmap.getHeight()); 87 int top = (faceRect.top+HEIGHT_OFFSET)*bitmap.getHeight()/FACE_X_RANGE; 88 int bottom = (faceRect.bottom+HEIGHT_OFFSET)*bitmap.getHeight()/FACE_X_RANGE; 89 int left = (faceRect.left+WIDTH_OFFSET)*bitmap [all...] |
/frameworks/opt/photoviewer/src/com/android/ex/photo/loaders/ |
H A D | PhotoBitmapLoader.java | 32 * Loader for the bitmap of a photo. 58 if (result.bitmap != null) { 59 result.bitmap.setDensity(DisplayMetrics.DENSITY_MEDIUM); 77 Bitmap bitmap = result != null ? result.bitmap : null; 81 if (bitmap != null) { 82 onReleaseResources(bitmap); 87 mBitmap = bitmap; 98 if (oldBitmap != null && oldBitmap != bitmap && !oldBitmap.isRecycled()) { 113 result.bitmap 168 onReleaseResources(Bitmap bitmap) argument [all...] |
H A D | PhotoBitmapLoaderInterface.java | 19 public Bitmap bitmap; field in class:PhotoBitmapLoaderInterface.BitmapResult 25 * the underlying bitmap is null). 36 // Don't create a new drawable if there's no bitmap. PhotoViewFragment regards 39 if (bitmap == null) { 43 return new BitmapDrawable(resources, bitmap);
|
/frameworks/base/core/jni/android/graphics/ |
H A D | Bitmap.h | 20 #include <android/bitmap.h> 30 namespace bitmap { namespace in namespace:android 38 jobject createBitmap(JNIEnv* env, Bitmap* bitmap, 45 Bitmap& toBitmap(JNIEnv* env, jobject bitmap); 49 void imageInfo(JNIEnv* env, jobject bitmap, AndroidBitmapInfo* info); 50 // Returns a pointer to the pixels or nullptr if the bitmap is not valid 51 void* lockPixels(JNIEnv* env, jobject bitmap); 52 // Returns true if unlocked, false if the bitmap is no longer valid (destroyed) 53 bool unlockPixels(JNIEnv* env, jobject bitmap); 55 /** Reinitialize a bitmap [all...] |
H A D | Bitmap.cpp | 51 BitmapWrapper(Bitmap* bitmap) argument 52 : mBitmap(bitmap) { } 68 Bitmap& bitmap() { function in class:android::BitmapWrapper 74 LOG_ALWAYS_FATAL_IF(!valid(), "Error, cannot access an invalid/free'd bitmap here!"); 158 return mBitmapWrapper->bitmap().pixels(); 169 namespace bitmap { namespace in namespace:android 171 // Assert that bitmap's SkAlphaType is consistent with isPremultiplied. 199 jobject createBitmap(JNIEnv* env, Bitmap* bitmap, argument 206 assert_premultiplied(bitmap->info(), isPremultiplied); 207 BitmapWrapper* bitmapWrapper = new BitmapWrapper(bitmap); 224 toBitmap(JNIEnv* env, jobject bitmap) argument 239 imageInfo(JNIEnv* env, jobject bitmap, AndroidBitmapInfo* info) argument 271 lockPixels(JNIEnv* env, jobject bitmap) argument 290 unlockPixels(JNIEnv* env, jobject bitmap) argument 420 ChooseFromColorProc(const SkBitmap& bitmap) argument 731 SkBitmap bitmap; local 830 auto bitmap = allocator.getStorageObjAndReset(); local 841 auto bitmap = allocator.getStorageObjAndReset(); local 850 auto bitmap = Bitmap_copyAshmemImpl(env, src, dstCT); local 859 auto bitmap = Bitmap_copyAshmemImpl(env, src, dstCT); local 864 Bitmap_destruct(BitmapWrapper* bitmap) argument 1183 SkBitmap bitmap; local 1356 SkBitmap bitmap; local 1388 SkBitmap bitmap; local 1436 SkBitmap bitmap; local 1466 SkBitmap bitmap; local 1474 SkBitmap bitmap; local 1489 SkBitmap bitmap; local 1605 sk_sp<Bitmap> bitmap = Bitmap::createFrom(buffer); local [all...] |
/frameworks/support/compat/tests/java/android/support/v4/graphics/drawable/ |
H A D | IconCompatTest.java | 49 private void verifyClippedCircle(Bitmap bitmap, int fillColor, int size) { argument 50 assertEquals(size, bitmap.getHeight()); 51 assertEquals(bitmap.getWidth(), bitmap.getHeight()); 52 assertEquals(fillColor, bitmap.getPixel(size / 2, size / 2)); 54 assertEquals(Color.TRANSPARENT, bitmap.getPixel(0, 0)); 55 assertEquals(Color.TRANSPARENT, bitmap.getPixel(0, size - 1)); 56 assertEquals(Color.TRANSPARENT, bitmap.getPixel(size - 1, 0)); 57 assertEquals(Color.TRANSPARENT, bitmap.getPixel(size - 1, size - 1)); 70 Bitmap bitmap [all...] |
/frameworks/base/core/tests/coretests/src/android/graphics/ |
H A D | BitmapFactoryTest.java | 41 Bitmap bitmap = BitmapFactory.decodeFileDescriptor(fd); 42 assertNotNull("BitmapFactory returned null", bitmap); 43 assertEquals("Bitmap width", 1, bitmap.getWidth()); 44 assertEquals("Bitmap height", 1, bitmap.getHeight());
|
/frameworks/base/native/graphics/jni/ |
H A D | bitmap.cpp | 17 #include <android/bitmap.h> 27 android::bitmap::imageInfo(env, jbitmap, info); 37 void* addr = android::bitmap::lockPixels(env, jbitmap); 53 bool unlocked = android::bitmap::unlockPixels(env, jbitmap);
|
/frameworks/opt/setupwizard/library/full-support/test/instrumentation/src/com/android/setupwizardlib/test/ |
H A D | DividerItemDecorationTest.java | 71 Bitmap bitmap = drawDecoration(decoration, true, true); 73 // Draw the expected result on a bitmap 82 assertBitmapEquals(expectedBitmap, bitmap); 84 bitmap.recycle(); 85 bitmap = drawDecoration(decoration, false, true); 87 assertBitmapEquals(expectedBitmap, bitmap); 89 bitmap.recycle(); 90 bitmap = drawDecoration(decoration, true, false); 95 assertBitmapEquals(expectedBitmap, bitmap); 97 bitmap [all...] |
/frameworks/base/libs/hwui/tests/unit/ |
H A D | SkiaBehaviorTests.cpp | 30 SkBitmap bitmap; local 32 bitmap.setInfo(info); 33 bitmap.allocPixels(info); 34 return bitmap; 49 SkBitmap bitmap; local 51 ASSERT_TRUE(s->isABitmap(&bitmap, nullptr, xy)) 52 << "1x1 bitmap shader must query as bitmap shader"; 55 EXPECT_EQ(origBitmap.pixelRef(), bitmap.pixelRef()); 59 SkBitmap bitmap local [all...] |
/frameworks/base/libs/hwui/tests/common/ |
H A D | BitmapAllocationTestUtils.h | 31 SkColorType colorType, std::function<void(SkBitmap& bitmap)> setup) { 32 sk_sp<Bitmap> bitmap = TestUtils::createBitmap(width, height, colorType); local 34 bitmap->getSkBitmap(&skBitmap); 36 return bitmap; 40 SkColorType colorType, std::function<void(SkBitmap& bitmap)> setup) { 50 std::function<void(SkBitmap& bitmap)> setup);
|
/frameworks/support/frameworks/support/samples/Support7Demos/src/com/example/android/supportv7/graphics/ |
H A D | ImageLoader.java | 41 void onImageLoaded(Bitmap bitmap); argument 70 protected void onPostExecute(Bitmap bitmap) { 71 imageView.setImageBitmap(bitmap); 73 if (bitmap != null) { 75 CACHE.put(id, bitmap); 78 listener.onImageLoaded(bitmap);
|