No matter the compressed size of a file, it resides uncompressed in memory. So, 512x512x4 = 1048576 (width * height * depth, where depth is 4 bytes/32 bits).
Ken [import]uid: 5742 topic_id: 2727 reply_id: 8116[/import]
Yip, that is what a lot of people forget. Inside the device, everything expands to its actual size. [import]uid: 5712 topic_id: 2727 reply_id: 8152[/import]
But lets take an other example: an image of 180*300
It should be rounded to the closer “power of two” dimensions: 256*512
So it should have an uncompressed file size of 256*512*4 = 524.288 kb
However, a print(system.getInfo(“textureMemoryUsed”)) calculates it to 216.000 kb
( 180*300*4=216.000 )
I have submitted an issue for this bug. [import]uid: 7356 topic_id: 2727 reply_id: 8168[/import]
Yes, I am also going to host my graphics in spritesheets.
Max supported dimension is 1024*1024 for now. [import]uid: 7356 topic_id: 2727 reply_id: 8174[/import]
the 4 bytes (32 bit) is RGBA (24-bit RGB + 8 bit alpha). This isn’t a Corona limitation - ios handles all uncompressed images this way. Hopefully, we’ll have the option of the much more efficient (albeit lossy) PVRTC texture support in a future release. [import]uid: 5742 topic_id: 2727 reply_id: 26516[/import]