Background
Using the Volley library's NetworkImageView is a convenient way to handle showing images from the web.
However, it has some bugs (as i've written here).
the problem
One of the issues that you can have by using it is that it doesn't decode the images from the web in a memory efficient way.
This means that if you use a gridView with multiple NetworkImageView in it, and each shows an image that has an unknown resolution (could be small, could be large), you would end up having an OOM .
as an example, you can set the url of this object to be this one and see for yourself how much memory the app uses after showing the bitmap, compared to how much it used before.
The question
How can i modify the way that NetworkImageView decodes the bitmap ?
One way I could change it is to make it decode the bitmap while downscaling it to the needed size (or at least set the max of it to the screen size), for example using this method of downscaling .