Android 将图片转化为缩略图再加载

      stream = new FileInputStream(new File(path+"test.jpg"));

  BitmapFactory.Options opts = new BitmapFactory.Options();

  opts.inSampleSize = 8;

  Bitmap bitmap = BitmapFactory.decodeStream(stream , null, opts);

  iv.setImageBitmap(bitmap);

你可能感兴趣的:(android,Stream,File,null,Path)