摘要:
错误:Cannot generate texture from bitmap。界面的ImageView显示一片黑色。原因:我是在调用Bitmap newBmp = Bitmap.createBitmap(originBmp, 0, 0, bmpW, bmpH, matrix, true)之后,就recycle originBmp, 谁知道当matrix.postScale(ratio, ratio)中的ratio = 1.0的时候,newBmp == originBmp, 所以此时不能recycle originBmp.解决办法:在recycle之前加一个判断语句:if(newBmp != o 阅读全文
浙公网安备 33010602011771号