Searched refs:bitmap (Results 26 - 50 of 140) sorted by relevance

123456

/frameworks/base/tests/DpiTest/src/com/google/android/test/dpi/
H A DDpiTestActivity.java89 addLabelToRoot(root, "Prescaled bitmap in drawable");
96 addLabelToRoot(root, "Autoscaled bitmap in drawable");
118 addLabelToRoot(root, "Prescaled bitmap");
125 addLabelToRoot(root, "Autoscaled bitmap");
165 Bitmap bitmap;
166 bitmap = loadAndPrintDpi(resource, scale);
170 final BitmapDrawable d = new BitmapDrawable(getResources(), bitmap);
191 Bitmap bitmap;
192 bitmap = loadAndPrintDpi(resource, scale);
194 ScaledBitmapView view = new ScaledBitmapView(this, bitmap);
229 ScaledBitmapView(Context context, Bitmap bitmap) argument
[all...]
/frameworks/base/core/java/android/view/
H A DPointerIcon.java44 /** Style constant: Custom icon with a user-supplied bitmap. */
47 /** Style constant: Null icon. It has no bitmap. */
82 * Gets a special pointer icon that has no bitmap.
149 * Creates a custom pointer from the given bitmap and hotspot information.
151 * @param bitmap The bitmap for the icon.
152 * @param hotspotX The X offset of the pointer icon hotspot in the bitmap.
153 * Must be within the [0, bitmap.getWidth()) range.
154 * @param hotspotY The Y offset of the pointer icon hotspot in the bitmap.
155 * Must be within the [0, bitmap
161 createCustomIcon(Bitmap bitmap, float hotSpotX, float hotSpotY) argument
412 validateHotSpot(Bitmap bitmap, float hotSpotX, float hotSpotY) argument
[all...]
H A DGLES20Layer.java56 boolean copyInto(Bitmap bitmap) { argument
57 return GLES20Canvas.nCopyLayer(mLayer, bitmap.mNativeBitmap);
H A DHardwareCanvas.java36 public void setBitmap(Bitmap bitmap) { argument
/frameworks/base/core/jni/android/graphics/
H A DBitmapRegionDecoder.cpp204 // Get the bitmap for re-use if it exists.
224 SkBitmap* bitmap = NULL; local
228 // Re-use bitmap.
229 bitmap = GraphicsJNI::getNativeBitmap(env, tileBitmap);
231 if (bitmap == NULL) {
232 bitmap = new SkBitmap;
233 adb.reset(bitmap);
236 if (!brd->decodeRegion(bitmap, region, prefConfig, sampleSize)) {
242 env->SetIntField(options, gOptions_widthFieldID, bitmap->width());
243 env->SetIntField(options, gOptions_heightFieldID, bitmap
[all...]
H A DBitmapFactory.cpp139 static SkPixelRef* installPixelRef(SkBitmap* bitmap, SkStream* stream, argument
144 if (bitmap->getSize() >= 32 * 1024) {
145 pr = new SkImageRef_ashmem(stream, bitmap->config(), sampleSize);
147 pr = new SkImageRef_GlobalPool(stream, bitmap->config(), sampleSize);
150 bitmap->setPixelRef(pr)->unref();
151 pr->isOpaque(bitmap);
197 return nullObjectReturn("Cannot pre-scale a reused bitmap");
212 SkBitmap* bitmap; local
214 bitmap = new SkBitmap;
217 return nullObjectReturn("SkImageDecoder: Cannot reuse bitmap wit
398 jobject bitmap = NULL; local
[all...]
H A DGraphics.cpp284 SkBitmap* GraphicsJNI::getNativeBitmap(JNIEnv* env, jobject bitmap) { argument
286 SkASSERT(bitmap);
287 SkASSERT(env->IsInstanceOf(bitmap, gBitmap_class));
288 SkBitmap* b = (SkBitmap*)env->GetIntField(bitmap, gBitmap_nativeInstanceID);
347 jobject GraphicsJNI::createBitmap(JNIEnv* env, SkBitmap* bitmap, jbyteArray buffer, argument
351 SkASSERT(bitmap);
352 SkASSERT(bitmap->pixelRef());
354 static_cast<jint>(reinterpret_cast<uintptr_t>(bitmap)),
360 jobject GraphicsJNI::createBitmap(JNIEnv* env, SkBitmap* bitmap, bool isMutable, argument
363 return createBitmap(env, bitmap, NUL
367 createBitmapRegionDecoder(JNIEnv* env, SkBitmapRegionDecoder* bitmap) argument
481 allocateJavaPixelRef(JNIEnv* env, SkBitmap* bitmap, SkColorTable* ctable) argument
518 allocPixelRef(SkBitmap* bitmap, SkColorTable* ctable) argument
[all...]
/frameworks/base/graphics/java/android/graphics/
H A DNinePatch.java21 * The NinePatch class permits drawing a bitmap in nine sections.
45 * Create a drawable projection from a bitmap to nine patches.
47 * @param bitmap The bitmap describing the patches.
49 * bitmap is split apart and drawn.
50 * @param srcName The name of the source for the bitmap. Might be null.
52 public NinePatch(Bitmap bitmap, byte[] chunk, String srcName) { argument
53 mBitmap = bitmap;
77 * Draw a bitmap of nine patches.
79 * @param canvas A container for the current matrix and clip used to draw the bitmap
156 validateNinePatchChunk(int bitmap, byte[] chunk) argument
163 nativeGetTransparentRegion( int bitmap, byte[] chunk, Rect location) argument
[all...]
/frameworks/ex/carousel/java/com/android/ex/carousel/
H A DCarouselRS.java609 public void setDefaultBitmap(Bitmap bitmap) argument
611 mScript.set_defaultTexture(allocationFromBitmap(bitmap, MIPMAP));
614 public void setLoadingBitmap(Bitmap bitmap) argument
616 mScript.set_loadingTexture(allocationFromBitmap(bitmap, MIPMAP));
649 private Allocation allocationFromBitmap(Bitmap bitmap, Allocation.MipmapControl mipmap) argument
651 if (bitmap == null) return null;
652 Allocation allocation = Allocation.createFromBitmap(mRS, bitmap,
657 private Allocation allocationFromPool(int n, Bitmap bitmap, Allocation.MipmapControl mipmap) argument
670 allocation = allocationFromBitmap(bitmap, mipmap);
672 } else if (bitmap !
718 setTexture(int n, Bitmap bitmap) argument
737 setDetailTexture(int n, float offx, float offy, float loffx, float loffy, Bitmap bitmap) argument
849 setBackgroundTexture(Bitmap bitmap) argument
858 setDetailLineTexture(Bitmap bitmap) argument
867 setDetailLoadingTexture(Bitmap bitmap) argument
917 elementForBitmap(Bitmap bitmap, Bitmap.Config defaultConfig) argument
[all...]
/frameworks/base/media/mca/filterpacks/java/android/filterpacks/imageproc/
H A DImageEncoder.java60 Bitmap bitmap = input.getBitmap();
61 bitmap.compress(CompressFormat.JPEG, mQuality, mOutputStream);
/frameworks/base/native/graphics/jni/
H A DAndroid.mk19 bitmap.cpp
/frameworks/base/services/input/
H A DSpriteController.h59 inline SpriteIcon(const SkBitmap& bitmap, float hotSpotX, float hotSpotY) : argument
60 bitmap(bitmap), hotSpotX(hotSpotX), hotSpotY(hotSpotY) { }
62 SkBitmap bitmap; member in struct:android::SpriteIcon
68 bitmap.copyTo(&bitmapCopy, SkBitmap::kARGB_8888_Config);
73 bitmap.reset();
79 return !bitmap.isNull() && !bitmap.empty();
102 /* Sets the bitmap that is drawn by the sprite.
103 * The sprite retains a copy of the bitmap fo
[all...]
/frameworks/base/libs/hwui/font/
H A DFont.h52 * If bitmap is specified, it will be used as the render target
55 int numGlyphs, int x, int y, uint8_t *bitmap = NULL,
85 int numGlyphs, int x, int y, RenderMode mode, uint8_t *bitmap,
104 uint8_t *bitmap, uint32_t bitmapW, uint32_t bitmapH,
107 uint8_t *bitmap, uint32_t bitmapW, uint32_t bitmapH,
110 uint8_t *bitmap, uint32_t bitmapW, uint32_t bitmapH,
/frameworks/base/media/mca/filterfw/java/android/filterfw/core/
H A DFrame.java118 public abstract void setBitmap(Bitmap bitmap); argument
181 protected static Bitmap convertBitmapToRGBA(Bitmap bitmap) { argument
182 if (bitmap.getConfig() == Bitmap.Config.ARGB_8888) {
183 return bitmap;
185 Bitmap result = bitmap.copy(Bitmap.Config.ARGB_8888, false);
187 throw new RuntimeException("Error converting bitmap to RGBA!");
189 throw new RuntimeException("Unsupported row byte count in bitmap!");
/frameworks/rs/
H A DrsFont.cpp112 uint8_t* bitmap, uint32_t bitmapW, uint32_t bitmapH) {
132 bitmap[bY * bitmapW + bX] = tempCol;
162 uint8_t *bitmap, uint32_t bitmapW, uint32_t bitmapH) {
206 drawCachedGlyph(cachedGlyph, penX, penY, bitmap, bitmapW, bitmapH);
250 FT_Bitmap *bitmap = &mFace->glyph->bitmap; local
252 // Now copy the bitmap into the cache texture
256 // Let the font state figure out where to put the bitmap
258 glyph->mIsValid = state->cacheBitmap(bitmap, &startX, &startY);
264 uint32_t endX = startX + bitmap
111 drawCachedGlyph(CachedGlyphInfo* glyph, int32_t x, int32_t y, uint8_t* bitmap, uint32_t bitmapW, uint32_t bitmapH) argument
159 renderUTF(const char *text, uint32_t len, int32_t x, int32_t y, uint32_t start, int32_t numGlyphs, RenderMode mode, Rect *bounds, uint8_t *bitmap, uint32_t bitmapW, uint32_t bitmapH) argument
410 cacheBitmap(FT_Bitmap *bitmap, uint32_t *retOriginX, uint32_t *retOriginY) argument
745 renderText(const char *text, uint32_t len, int32_t x, int32_t y, uint32_t startIndex, int32_t numGlyphs, Font::RenderMode mode, Font::Rect *bounds, uint8_t *bitmap, uint32_t bitmapW, uint32_t bitmapH) argument
839 fitBitmap(FT_Bitmap_ *bitmap, uint32_t *retOriginX, uint32_t *retOriginY) argument
[all...]
/frameworks/base/libs/hwui/
H A DLayerRenderer.cpp359 bool LayerRenderer::copyLayer(Layer* layer, SkBitmap* bitmap) { argument
361 if (layer && bitmap->width() <= caches.maxTextureSize &&
362 bitmap->height() <= caches.maxTextureSize) {
370 SkAutoLockPixels alp(*bitmap);
382 switch (bitmap->config()) {
419 glPixelStorei(GL_PACK_ALIGNMENT, bitmap->bytesPerPixel());
427 glTexImage2D(GL_TEXTURE_2D, 0, format, bitmap->width(), bitmap->height(),
437 renderer.setViewport(bitmap->width(), bitmap
[all...]
H A DShapeCache.h339 PathTexture* addTexture(const Entry& entry, SkBitmap* bitmap);
340 void addTexture(const Entry& entry, SkBitmap* bitmap, PathTexture* texture);
348 void initBitmap(SkBitmap& bitmap, uint32_t width, uint32_t height);
369 * Generates the texture from a bitmap into the specified texture structure.
371 void generateTexture(SkBitmap& bitmap, Texture* texture);
525 // Don't even try to cache a bitmap that's bigger than the cache
534 void ShapeCache<Entry>::initBitmap(SkBitmap& bitmap, uint32_t width, uint32_t height) { argument
535 bitmap.setConfig(SkBitmap::kA8_Config, width, height);
536 bitmap.allocPixels();
537 bitmap
575 SkBitmap bitmap; local
592 addTexture(const Entry& entry, SkBitmap* bitmap, PathTexture* texture) argument
615 generateTexture(SkBitmap& bitmap, Texture* texture) argument
[all...]
H A DShapeCache.cpp119 SkBitmap bitmap; local
120 initBitmap(bitmap, rectWidth, rectHeight);
125 SkCanvas canvas(bitmap);
130 addTexture(entry, &bitmap, texture);
/frameworks/base/core/java/android/text/style/
H A DImageSpan.java134 Bitmap bitmap = null;
138 bitmap = BitmapFactory.decodeStream(is);
139 drawable = new BitmapDrawable(mContext.getResources(), bitmap);
/frameworks/base/graphics/java/android/graphics/drawable/
H A DNinePatchDrawable.java42 * A resizeable bitmap, with stretchable areas that you define. This type of image
78 public NinePatchDrawable(Bitmap bitmap, byte[] chunk, Rect padding, String srcName) { argument
79 this(new NinePatchState(new NinePatch(bitmap, chunk, srcName), padding), null);
86 public NinePatchDrawable(Resources res, Bitmap bitmap, byte[] chunk, argument
88 this(new NinePatchState(new NinePatch(bitmap, chunk, srcName), padding), res);
98 public NinePatchDrawable(Resources res, Bitmap bitmap, byte[] chunk, argument
100 this(new NinePatchState(new NinePatch(bitmap, chunk, srcName), padding, layoutInsets), res);
303 Bitmap bitmap = null;
309 bitmap = BitmapFactory.decodeResourceStream(r, value, is, padding, options);
316 if (bitmap
[all...]
/frameworks/base/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/impl/
H A DResourceHelper.java163 * @param value The value that contains a path to a 9 patch, a bitmap or a xml based drawable,
229 Bitmap bitmap = Bridge.getCachedBitmap(stringValue,
232 if (bitmap == null) {
233 bitmap = Bitmap_Delegate.createBitmap(bmpFile, false /*isMutable*/,
235 Bridge.setCachedBitmap(stringValue, bitmap,
239 return new BitmapDrawable(context.getResources(), bitmap);
264 // see if we still have both the chunk and the bitmap in the caches
267 Bitmap bitmap = Bridge.getCachedBitmap(cacheKey,
270 // if either chunk or bitmap is null, then we reload the 9-patch file.
271 if (chunk == null || bitmap
[all...]
/frameworks/ex/carousel/test/src/com/android/carouseltest/
H A DTaskSwitcherActivity.java145 Bitmap bitmap = desc.thumbnail == null ? mBlankBitmap : desc.thumbnail;
146 return bitmap;
151 Bitmap bitmap = null;
154 bitmap = Bitmap.createBitmap(DETAIL_TEXTURE_WIDTH, DETAIL_TEXTURE_HEIGHT,
156 Canvas canvas = new Canvas(bitmap);
163 return bitmap;
173 public void newThumbnail(final int id, final Bitmap bitmap, CharSequence description)
175 int w = bitmap.getWidth();
176 int h = bitmap.getHeight();
181 info.thumbnail = bitmap;
[all...]
/frameworks/base/core/jni/
H A Dandroid_view_PointerIcon.cpp80 SkBitmap* bitmap = GraphicsJNI::getNativeBitmap(env, bitmapObj); local
81 if (bitmap) {
82 outPointerIcon->bitmap = *bitmap; // use a shared pixel ref
/frameworks/base/policy/src/com/android/internal/policy/impl/keyguard/
H A DKeyguardCircleFramedDrawable.java52 public KeyguardCircleFramedDrawable(Bitmap bitmap, int size, argument
67 final int width = bitmap.getWidth();
68 final int height = bitmap.getHeight();
88 // mask in the icon where the bitmap is opaque
90 canvas.drawBitmap(bitmap, cropRect, circleRect, mPaint);
/frameworks/base/media/java/android/media/
H A DRemoteControlClient.java484 * @param key the identifier of the bitmap to set. The only valid value is
486 * @param bitmap The bitmap for the artwork, or null if there isn't any.
492 public synchronized MetadataEditor putBitmap(int key, Bitmap bitmap) argument
502 mEditorArtwork = scaleBitmapIfTooBig(bitmap,
506 mEditorArtwork = bitmap;
763 * Cache for the artwork bitmap.
765 * Artwork and metadata are not kept in one Bundle because the bitmap sometimes needs to be
1012 // send the bitmap, there might be newer and smaller expected dimensions, so we have
1027 // send the bitmap, ther
1117 scaleBitmapIfTooBig(Bitmap bitmap, int maxWidth, int maxHeight) argument
[all...]

Completed in 1029 milliseconds

123456