Android graphics problem (build 2011.703)

Folks,

I’m having a problem with graphics in build 2011.703. When I build for Android and install on a device, some of the graphics assets don’t display correctly. Some of the images are not rendered and are replaced with black rectangles.

This doesn’t seem to be a problem on iOS builds.

It’s also not a problem on 2011.591 builds for Android.

The problem persists whether I compile on Mac or PC.

Has anyone else seen this problem? Does anyone have a fix?

Thanks. [import]uid: 76436 topic_id: 19801 reply_id: 319801[/import]

There could be some problem with the naming of the image files and the respective code.

I always use small letters for my assets, and the same for the code.

Joakim [import]uid: 81188 topic_id: 19801 reply_id: 76767[/import]

Thanks Joakim, but that’s not it. I also always use lower case letters for assets - great minds, right :-).

  • If it was an uppercase / lowercase problem the app would crash or throw. (this has happened to me before :slight_smile: )
  • Furthermore, I use the same code / asset name in multiple places and it works intermittently. for example, it works fine once, then I return to that screen later in the app and it fails. Or it works with one widget and fails for its brother widget on the same screen.
  • Also, it works fine with the .591 build, but not with the .703 build - so I think it’s Corona build specific.

Let me know if you have any other ideas…

Cheers.

[import]uid: 76436 topic_id: 19801 reply_id: 76780[/import]

Hey there,

Android is not my area but I have encountered a similar issue on iOS when my graphics files haven’t been right.

Images have to be RGB color space, 8 Bit, NOT indexed.

Maybe worth a look?

Peach :slight_smile: [import]uid: 52491 topic_id: 19801 reply_id: 76858[/import]

Hi Peach,

Thanks for the input, but that’s not the problem. All my images are the same. All 8-bit RGB.

As I said, it works on a previous build of Corona, just not on the latest (.703) build. Also, the problem occurs with some Corona generated text too, not just with images. And it’s fine when I build for iOS (exactly the same code).

It’s like the rendering engine just gets confused and throws up solid rectangles instead of text / images - and there’s no rhyme or reason as to which text / graphics resources are effected.

It seems to happen on larger apps - so I’m thinking it might be a memory management thing. But that doesn’t explain why it works with the previous Corona build…

Does anyone else have any ideas? Has anyone else seen something like this?

Thanks. [import]uid: 76436 topic_id: 19801 reply_id: 76880[/import]

Hey again,

Would you be able to file a bug report, please?
http://developer.anscamobile.com/content/bug-submission

If you could post the bug # here afterwards I can bring it up in our next meeting as well to try and get some info or a fix.

Peach :slight_smile: [import]uid: 52491 topic_id: 19801 reply_id: 76918[/import]

Thanks Peach. Dare I say it… you’re a peach!

I’ve submitted a report. I’ll let you know when I get a bug #.

I’ve been having a few troubles with .703/4. For example, I had a situation where the alpha of a graphics object suddenly started being applied to everything in its display group. I’ve also seen the display rendering on the sim go “nuts”, meaning that the image would shrink to half its size every time there was a “touch” event. Until there was nothing left of the image.

Thanks again.

Alan [import]uid: 76436 topic_id: 19801 reply_id: 76926[/import]

Haha, thanks.

I haven’t had any troubles with 703/704 yet, however it could still happen - I’ve not been as active during the holidays.

Please do let me know when you have a bug (or case) # handy.

Peach :slight_smile: [import]uid: 52491 topic_id: 19801 reply_id: 76937[/import]

Hi Peach,

Dumb question, but when/where/how do I get a bug#? It’s been a couple of days and I haven’t heard back from tech support - is there somewhere I go to look this up? Or do I wait until they create a case for me?

Thanks a bunch [import]uid: 76436 topic_id: 19801 reply_id: 77332[/import]

Uh, go here; http://developer.anscamobile.com/content/bug-submission

Up top it should mention “looking for previous submissions?” or the like and if you click that will show up bugs you’ve reported with #s to the left :slight_smile: [import]uid: 52491 topic_id: 19801 reply_id: 77487[/import]

Ok, so maybe I’m still dumb, but I can’t see the link for: “previous submissions”… I’ll take another look… [import]uid: 76436 topic_id: 19801 reply_id: 77542[/import]

I can’t see it either - so theres something strange with my account as well :frowning:

Joakim [import]uid: 81188 topic_id: 19801 reply_id: 77561[/import]

Thanks Joakim… I’m beginning to think I’m losing what’s left of my mind :slight_smile: [import]uid: 76436 topic_id: 19801 reply_id: 77562[/import]

Hi Peach, I just resubmitted the bug (just to be sure), and I didn’t get a bug number, and there’s nowhere that I can find on the bug page that will let me search for previous bugs. I don’t have “Premium Support”. Does that make a difference?

For the record, the title of the bug is:

“Graphical resources failing on Android platform (duplicate)”

Thanks again for your help. I really need this resolved if I’m going to hit my next development schedule…

Of course, it could be PEBCaK (Problem Exists Between Chair and Keyboard)

Cheers,

Alan
[import]uid: 76436 topic_id: 19801 reply_id: 77674[/import]

Hey guys,

Sorry - no idea what is up with that. (Maybe it’s a new feature that is still being tested and thus not visible from non-staff accounts? I don’t know. I’m theorizing now.)

Doing a search for the bug now…

11260 is the bug number.

Will pass it along :slight_smile: [import]uid: 52491 topic_id: 19801 reply_id: 77698[/import]

How big are the images that appear as black rectangles? I ran into what sounds like the same issue a while back when I was experimenting with very large image sizes. It sounds like a problem with using too much memory on android device. [import]uid: 38820 topic_id: 19801 reply_id: 77726[/import]

Hi Glen,

thanks for the feedback. I have a suspicion its a memory issue too. But these are pretty small images - and I’ve played with shrinking them down too.

How did you solve your problem?

Also, It’s happening on some really small stuff - including Corona-generated text.

Is it possible that something big is chewing up the texture memory and then the little stuff can’t get rendered?

Or that I have too many objects (I have between 50 and 200 on screen at once)? I’ve used more than this in the past, of course…

[import]uid: 76436 topic_id: 19801 reply_id: 77749[/import]

Have a look at how much texture memory your using and or if you have any memory leaks that might be causing problems too. The following post shows how to do it if your not sure how http://blog.anscamobile.com/2011/08/corona-sdk-memory-leak-prevention-101/

[import]uid: 38820 topic_id: 19801 reply_id: 77794[/import]

Thanks Glenn,

I’ll definitely keep exploring the memory angle.

[import]uid: 76436 topic_id: 19801 reply_id: 77796[/import]

Hey Glenn (or anyone else with some ideas),

Just ran an experiment. Measured texture memory on the app: about 11.7MB (not too terrible - is it?).

I built it with both SDK 2011.591 and SDK 2011.704

In both cases, the texture memory pegged at about 11.7MB (I’m pretty careful about avoiding leaks)

The .591 build worked perfectly… the .704 build spat the dummy! Resources randomly disappearing all over the shop!

There really seems to be something funny with the .704 build… or with me!

[import]uid: 76436 topic_id: 19801 reply_id: 77803[/import]