网络图片链接:http://www.x-navi.cn/images/map_blocks/2/6/6/6/00000069_00000069.png
正常显示:
[img]http://www.x-navi.cn/images/map_blocks/2/6/6/6/00000069_00000069.png[/img]
但是在android下面显示却变的模糊了
[img]/upload/attachment/101674/3238f93c-e800-3ea9-a438-da6ea3f07d26.jpg[/img]
图中显示的一个是网络链接图片(模糊),一个是本地图片(清晰)
代码如下:
不知道问题在哪里?请各位查看一下。谢
正常显示:
[img]http://www.x-navi.cn/images/map_blocks/2/6/6/6/00000069_00000069.png[/img]
但是在android下面显示却变的模糊了
[img]/upload/attachment/101674/3238f93c-e800-3ea9-a438-da6ea3f07d26.jpg[/img]
图中显示的一个是网络链接图片(模糊),一个是本地图片(清晰)
代码如下:
URL url = null;
try {
url = new URL(urlStr);
HttpURLConnection conn = (HttpURLConnection) url.openConnection();
in = conn.getInputStream();
bitmap = BitmapFactory.decodeStream(in);
} catch (IOException e1) {
e1.printStackTrace();
}finally{
try {
if(in != null)
in.close();
} catch (IOException e) {
e.printStackTrace();
}
}
canvas.drawBitmap(bitmap, 0,0, paint);
不知道问题在哪里?请各位查看一下。谢