How can i manage the memory for the following situation?
Bitmap bitmap = myBitmapProvider.getBitmap();
myImage.setImageBitmap(bitmap);
Based on my understanding this would cause a memory leak (And yes I am getting out of memory crashes) // I tried the following code but it crasshed the app because the bitmap is in-use by my ImageView, so what is the correct solution\?
bitmap.recycle();
bitmap = null;