Negative Texture Memory reported

In my app., using a simple statement like

print("Texture memory used: " .. system.getInfo("textureMemoryUsed"))

will sometimes print a *negative* result to the console, i.e. “Texture memory used: -1113952”. (It’s consistently in the same place when it does happen).

Also, I’ve often see wildly different texture memory usage reported on an actual device vs. on the Corona simulator. For example, during some testing of my app I displayed texture memory used and saw results like 0.021 mb on the device and Xcode sim, and 5.094 mb on the Cornoa sim.

I think there must be a bug or two in the way system.getInfo(“textureMemoryUsed”) polls the system. Any idea what’s going on? It’s pretty crucial to know the reality of texture memory usage during development, and right now I can’t say I trust any of the numbers I see.

[import]uid: 9422 topic_id: 3531 reply_id: 303531[/import]

Hello mate.
I have been facing the same issue. Have you got any reply with this regard, or have you knew why this happens?

Thanks [import]uid: 11038 topic_id: 3531 reply_id: 14887[/import]

Nope, no reply from anyone. I was hoping someone from Ansca would chime in. I’m still seeing negative texture memory usage reported on the device while the simulator reports seem more realistic, but who knows? At this point I don’t trust either number.

It’s been my experience with Corona development that there’s a lot of disparity between the simulator and an actual device. I’d say 90% of my time spent tracking down and fixing problems occurs because I made a change that worked fine on the simulator but failed on the device.

There’s a particularly nasty bug in the latest Corona build, in the new sound API, that’s currently blocking my own development. It, too, only shows up on device builds. I hope Ansca changes their testing procedure for new features to make sure they actually work as advertised on real phones, not just the simulator.
[import]uid: 9422 topic_id: 3531 reply_id: 14891[/import]

I also have negative texture memory values on XCode iPhone Simulator and Device. It seems like memory usage counter starts from 0 on Corona Simulator and from something like -34536 on Device (tested on iPad with iOS 3.2) and iPhone Simulator.
And yes, things that work on Corona Simulator and do not work on Device are irritate the most. [import]uid: 7301 topic_id: 3531 reply_id: 14995[/import]

Well, that’s 3 of us. How about it, Ansca? Does this qualify as a bug? Care to comment or acknowledge? [import]uid: 9422 topic_id: 3531 reply_id: 15130[/import]

Ansca, what the fuck is going on? You very likes post advertisings in your blog, but how about answering developer’s questions and fix bugs? Two(!) months passed! No one answers! No fixes [import]uid: 8850 topic_id: 3531 reply_id: 25718[/import]

Hi,

This bug was fixed in the latest daily build (available to subscribers):

http://developer.anscamobile.com/release/2011/308

Tim [import]uid: 8196 topic_id: 3531 reply_id: 25725[/import]

No, it’s not fixed. Or i doing something wrong.
See here: http://dl.dropbox.com/u/8121096/Archive.zip
All Ok on simulator.
Unpredictable behaviour system.getInfo(“textureMemoryUsed”) on device still exists.

(iPod Touch 2G 3.1, iPhone 3GS 4.2.1)

[import]uid: 8850 topic_id: 3531 reply_id: 25782[/import]

Build 308 definitely does *not* fix it for me. Here are some example texture memory read-outs from my app. comparing simulator vs. iPhone 3GS vs. iPhone 4.

Corona Sim: 3576 kb
iP 4: -3640 kb
iP 3gs: -903 kb

Corona Sim: 3113 kb
iP 4: -10998 kb
iP 3gs: -1454 kb

Corona Sim: 4620 kb
iP 4: -9581 kb
iP 3gs: -37 kb

Corona Sim: 1874 kb
iP 4: -12150 kb
iP 3gs: -2696 kb

Corona Sim: 4892 kb
iP 4: -3019 kb
iP 3gs: 398 kb

Corona Sim: 5035 kb
iP 4: -2507 kb
iP 3gs: 548 kb
Identical code base, but hi res. textures are being used for some graphics on the iPhone 4 which is why those number are bigger than on the 3GS. Still lots of negative texture memory reported on devices.
[import]uid: 9422 topic_id: 3531 reply_id: 25820[/import]