Android colored boxes instead of image

Hi!

I give up. I can´t understand what is going on. My app runs perfectly on iPhone and iPad (of course), but on Android some of the images turn to colored boxes sometimes. Especially when I suspend the app and resume.

What is going on? The images I use are not big. In fact in my example the image is only 112px X 81px.

I tried this on two Android devices with the same result. If there is any pattern I would say that it seems like this happens more frequently if the image has more transparent pixels.

I searched everywhere for answers and turned on the largeHeap if this was a memory issue. But how can this be a memory issue when I use tiny images?!?

Please help  :frowning:

Here is how it should look like:

http://appkokken.no/corona/IMG_5637.png

But sometimes there is a black box instead of the image:

http://appkokken.no/corona/IMG_5636.png

And now the box is blue:

http://appkokken.no/corona/IMG_5638.png

As you see the buttons are fine.

Have you considered your images of being corrupt? Have you tired downloading one or two off google and putting that in? 

If you hired someone for graphics maybe they compressed the images the wrong way although i dont know how that would happen but iv’e seen photo shop do such a thing before. 

–SonicX278 

That is a great tip, thanx!

I have used photoshop and https://tinypng.com to compress some of the images. I guess compressing the images may have something to do with it, although some of the images that don´t always work have not been compressed.

The only difference from previous apps is that I have used Photoshop instead of GIMP to edit the images.

I guess I will return to GIMP and see if that helps  :wink:

Thanx  :smiley:

SonicX278, you saved me  :rolleyes:

I checked ALL my images and I have a lot of them. I wanted to see if any of them were corrupt as you suggested.

It turned out my transparent.png image was corrupt. I used it as the defaultFile and overFile for a button on top of some the images.

So it wasn’t the animal images underneath that were the problem, it was the buttons image file.

Oooooh snap, I wish I would have asked for help earlier. Well you solved it…Thanx a lot  :smiley:

Awesome! Glad to help!

–SonicX278 

Have you considered your images of being corrupt? Have you tired downloading one or two off google and putting that in? 

If you hired someone for graphics maybe they compressed the images the wrong way although i dont know how that would happen but iv’e seen photo shop do such a thing before. 

–SonicX278 

That is a great tip, thanx!

I have used photoshop and https://tinypng.com to compress some of the images. I guess compressing the images may have something to do with it, although some of the images that don´t always work have not been compressed.

The only difference from previous apps is that I have used Photoshop instead of GIMP to edit the images.

I guess I will return to GIMP and see if that helps  :wink:

Thanx  :smiley:

SonicX278, you saved me  :rolleyes:

I checked ALL my images and I have a lot of them. I wanted to see if any of them were corrupt as you suggested.

It turned out my transparent.png image was corrupt. I used it as the defaultFile and overFile for a button on top of some the images.

So it wasn’t the animal images underneath that were the problem, it was the buttons image file.

Oooooh snap, I wish I would have asked for help earlier. Well you solved it…Thanx a lot  :smiley:

Awesome! Glad to help!

–SonicX278