private Bitmap getBitmap(String path) throws Exception { if(!path.equals("")){ URL u = new URL(path); HttpURLConnection conn = (HttpURLConnection)u.openConnection(); conn.setDoInput(true); // conn.connect(); InputStream localInputStream; Bitmap localBitmap ; localInputStream = conn.getInputStream(); localBitmap = BitmapFactory.decodeStream(localInputStream, null, null); return localBitmap; } return null; }
沒有留言:
張貼留言