Get bitmap width and height without loading to memory
http://stackoverflow.com/questions/11681274/get-bitmap-width-and-height-without-loading-to-memory
BitmapFactory.Options bitmapOptions =newBitmapFactory.Options();
bitmapOptions.inJustDecodeBounds =true;BitmapFactory.decodeStream(inputStream,null, bitmapOptions);int imageWidth = bitmapOptions.outWidth;int imageHeight = bitmapOptions.outHeight;
inputStream.close();
全站熱搜