R.drawable 转 bitmap

引用:http://zhidao.baidu.com/question/291703800.html

Bitmap bmp=BitmapFactory.decodeResource(r, R.drawable.icon);
Bitmap newb = Bitmap.createBitmap( 300, 300, Config.ARGB_8888 ); 
Canvas canvasTemp = new Canvas( newb );  
 canvasTemp.drawBitmap(bmp, 50, 50, p);

你可能感兴趣的:(drawable)