Bitmap bm = Bitmap.createBitmap(bitmap, 0, 0, bitmap.getWidth(),
bitmap.getHeight(), matrix, true);
就是这条语句,经常报java.lang.outofMemoryError错误?各位大牛谁知道,可以改一个其他的方法吗?
Bitmap bm = Bitmap.createBitmap(bitmap, 0, 0, bitmap.getWidth(),
bitmap.getHeight(), matrix, true);
就是这条语句,经常报java.lang.outofMemoryError错误?各位大牛谁知道,可以改一个其他的方法吗?
是不是因为你的图片太大了,把它换为android自带的图标试试。或者直接使用Canvas.drawBitmap(Bitmap bitmap, Matrix matrix, Paint paint)方法重绘一张好了,不用重新生成新图。