【发布时间】:2011-06-20 15:34:44
【问题描述】:
我在 SD 卡中保存了一个透明的 PNG 图像。我想显示的是现在。我为此使用了以下代码。
selected_photo = (ImageView) findViewById(R.id.selected_photo);
Uri photoUri = Uri.parse(photoPath);
selected_photo.setImageBitmap(MediaStore.Images.Media.getBitmap(getContentResolver(),photoUri));
但它在显示中给出了不透明的图像。如何在不丢失透明度的情况下显示PNG图像?
【问题讨论】:
标签: android image png transparency sd-card