1
0
mirror of https://github.com/wasabeef/glide-transformations.git synced 2025-06-09 07:54:04 +08:00

fix blur not working

This commit is contained in:
wasabeef 2015-07-18 01:47:43 +09:00
parent e23753044e
commit 32d0c1de82

View File

@ -54,11 +54,9 @@ public class BlurTransformation implements Transformation<Bitmap> {
int width = source.getWidth(); int width = source.getWidth();
int height = source.getHeight(); int height = source.getHeight();
Bitmap.Config config = Bitmap bitmap = mBitmapPool.get(width, height, Bitmap.Config.ARGB_8888);
source.getConfig() != null ? source.getConfig() : Bitmap.Config.ARGB_8888;
Bitmap bitmap = mBitmapPool.get(width, height, config);
if (bitmap == null) { if (bitmap == null) {
bitmap = Bitmap.createBitmap(width, height, config); bitmap = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888);
} }
Canvas canvas = new Canvas(bitmap); Canvas canvas = new Canvas(bitmap);