正确方法:
Drawable d =new BitmapDrawable(context.getResources(),bitmap);
过时方法:
Drawable d =new BitmapDrawable(bitmap);
不使用getResource()参数很有可能会导致bitmap无法正常渲染,甚至不能正确缩放等等一系列问题。
正确方法:
Drawable d =new BitmapDrawable(context.getResources(),bitmap);
Drawable d =new BitmapDrawable(bitmap);
不使用getResource()参数很有可能会导致bitmap无法正常渲染,甚至不能正确缩放等等一系列问题。