Bitmap bitmapOrg = BitmapFactory.decodeResource(getResources(),
               R.drawable.xxxxx);        int width = bitmapOrg.width();
        int height = bitmapOrg.height();
       
        float scaleWidth = 0.5;
        float scaleHeight = 0.5;        Matrix matrix = new Matrix();        // resize the bit map
        matrix.postScale(scaleWidth, scaleHeight);
 
        // recreate the new Bitmap
        Bitmap resizedBitmap = Bitmap.createBitmap(bitmapOrg, 0, 0,
                          width, height, matrix, true); 作为参考

解决方案 »

  1.   

    BitmapFactory.Options.inSampleSize = n;
      

  2.   

    貌似你是想把Activity画面,生成缩略图片,在系统manager里面有这个方法~
      

  3.   

    没研究过,不过可以参考android源码里的图片显示方法,生成缩略图
      

  4.   


    很好,ThumbnailUtils里面主要的内容也就是这部分了。
      

  5.   

    系统manager在哪里额?找不到额。。