|
|
|
[Android] อยาก resize ภาพที่มาจาก Drawable LoadImageFromWebOperations ต้องทำอย่างไรค่ะ |
|
|
|
|
|
|
|
Code (Android-Java)
byte[] imageAsBytes=null;
try {
imageAsBytes = Base64.decode(encodedImage.getBytes());
} catch (IOException e) {
e.printStackTrace();
}
Bitmap b = BitmapFactory.decodeByteArray(imageAsBytes, 0, imageAsBytes.length)
image.setImageBitmap(Bitmap.createScaledBitmap(b, 120, 120, false));
http://stackoverflow.com/questions/4837715/how-to-resize-a-bitmap-in-android
|
ประวัติการแก้ไข 2013-07-18 12:29:11
|
|
|
|
Date :
2013-07-18 12:10:11 |
By :
zFOLKz |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Date :
2013-07-18 13:01:22 |
By :
mr.win |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Load balance : Server 02
|