Dhaval
Dhaval

Reputation: 2874

How to solve Out of memory on a 8294416-byte allocation exception?

I am making an application to display slideshow of images and videos. I am using ViewFlipper to flip videos and images. Moreover, I am using Picasso library to display image from local storage. Now, when I try to run the application at some point it is running perfectly. But once in a while, I a getting the exception Out of memory on a 8294416-byte allocation. I googled it and find one solution that using "android:largeHeap=true" I could solve the issue. But it didn't worked for me. Do anyone knows how to solve it?

Here is my logcat showing the error : enter image description here

Upvotes: 0

Views: 778

Answers (1)

Francesco verheye
Francesco verheye

Reputation: 1574

This is a good training to load large Bitmaps in Android

https://developer.android.com/training/displaying-bitmaps/load-bitmap.html

Edit This is another SO answer which is related to Picasso. Look at .resize(width, height) https://stackoverflow.com/a/23741267/1723525

Upvotes: 2

Related Questions