BitmapDrawable localBitmapDrawable = new BitmapDrawable(paramBitmap);
原本的density
[quote]paramBitmap240[/quote]
变成了
[quote]localBitmapDrawable 160[/quote]
lookit
/**
* Create drawable from a bitmap, setting initial target density based on
* the display metrics of the resources.
*/
public BitmapDrawable(Resources res, Bitmap bitmap) {
this(new BitmapState(bitmap), res);
mBitmapState.mTargetDensity = mTargetDensity;
}
纠结了好多天了!