I've got a GridView of many images which are retrieved from the assets folder and decoded from streams. These are t开发者_JS百科ypically quite large (to be used elsewhere in the app), but for the GridView need to only be 140dp wide or have a minimum height of 150dp. Which of the options in BitmapFactory.Options should I use to scale the image to this density/resolution? I'm confused by the many different density options.
For fast retrieval, you should use inSampleSize. It automatically loads a smaller bitmap without first loading the full image into memory.
 
         
                                         
                                         
                                         
                                        ![Interactive visualization of a graph in python [closed]](https://www.devze.com/res/2023/04-10/09/92d32fe8c0d22fb96bd6f6e8b7d1f457.gif) 
                                         
                                         
                                         
                                         加载中,请稍侯......
 加载中,请稍侯......
      
精彩评论