public static int computeSampleSize(BitmapFactory.Options options, int minSideLength, int maxNumOfPixel...
1、Drawable → Bitmappublic static Bitmap drawableToBitmap(Drawable drawable) { Bitmap bitmap = Bitmap .createBitmap( ...
Bitmap bitmap = BitmapFactory.decodeResource(r, R.drawable.icon).copy(Bitmap.Config.ARGB_8888, true)加上.copy(Bitmap.Config.ARGB_8888, true)原因是如果不用copy的...