diff options
Diffstat (limited to 'libs/hwui/TextureCache.cpp')
-rw-r--r-- | libs/hwui/TextureCache.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/libs/hwui/TextureCache.cpp b/libs/hwui/TextureCache.cpp index d860953bc247..0c7948f70f98 100644 --- a/libs/hwui/TextureCache.cpp +++ b/libs/hwui/TextureCache.cpp @@ -200,9 +200,13 @@ void TextureCache::generateTexture(SkBitmap* bitmap, Texture* texture, bool rege texture->blend = !bitmap->isOpaque(); break; case SkBitmap::kIndex8_Config: - uploadPalettedTexture(resize, bitmap, texture->width, texture->height); + uploadLoFiTexture(resize, bitmap, texture->width, texture->height); texture->blend = false; break; + case SkBitmap::kARGB_4444_Config: + uploadLoFiTexture(resize, bitmap, texture->width, texture->height); + texture->blend = true; + break; default: LOGW("Unsupported bitmap config: %d", bitmap->getConfig()); break; @@ -215,7 +219,7 @@ void TextureCache::generateTexture(SkBitmap* bitmap, Texture* texture, bool rege glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE); } -void TextureCache::uploadPalettedTexture(bool resize, SkBitmap* bitmap, +void TextureCache::uploadLoFiTexture(bool resize, SkBitmap* bitmap, uint32_t width, uint32_t height) { SkBitmap rgbaBitmap; rgbaBitmap.setConfig(SkBitmap::kARGB_8888_Config, width, height); |