import file size, vs properies file size question

Discussion and feedback on Construct 2

Post » Thu Feb 06, 2014 7:09 pm

Hi everyone,

So I was just wondering that if i were bring a graphic in that was sized to 300x300.. but i want it to actually be 256x256 to help save memory. if i set the size in C2 of a graphic to be a different size, does that effect the memory footprint, or is the graphic still going to take 300x300 (or 512x512) pixel worth of mobile memory?

I have a project that the art wasn't optimized for mobile and looking to explore solutions that would prevent me from having to re-import a number of graphics with optimized ones. Would rather just be able to optimize them from within C2.

Thanks!
Caleb
B
56
S
9
G
1
Posts: 938
Reputation: 6,458

Post » Fri Feb 07, 2014 3:41 pm

more on this question.. I'm just wondering if there are ways to resize things in C2. if my project was in 1080p.. and i want to take it down to 720p.. does making the images smaller on the screen reduce the memory they occupy in graphic memory?

Or perhaps the graphic integrity is retained regardless of what size I have it appear in the game.. for example.. if i had a 512x512 image and sized it down to 128x128, does C2 do anything to crop/scale adjust the amount of graphic memory used?
B
56
S
9
G
1
Posts: 938
Reputation: 6,458

Post » Fri Feb 07, 2014 4:55 pm

The images are stored in memory at the size you see them in the image editor, regardless of the runtime or layout view scaling.

It's not actually usually important for sprites to be a power-of-two size, since whatever size they are they get spritesheeted on to a larger power-of-two size texture.
Scirra Founder
B
387
S
230
G
87
Posts: 24,249
Reputation: 192,250

Post » Mon Feb 10, 2014 3:25 pm

Hi Ashley, thanks for the clearing this up, but if I may inquire further, when I export a project to HTML5 for basic web gameplay, I end up with hundreds of pngs of whatever size. These do not appear to be spritesheeted (other than animations) so my concern is that when i go to load one of these games on iOS, i notice pretty much non responsive.

However, perhaps you're saying that when I go to use CocoonJS, they make a spritesheet? I raise this question because I have a game that plays fine on PC browser, but it crashes on iOS. It starts to load and then after a few seconds after i hear the music load and play it crashes.

It feels to me like it's a memory issue, as that has been my experience with GameSalad and retina graphics, where I have lots of high rez images.. in this current project I'm doing its at 1920x1080 so getting that to work on an iPad mini or iPad2.. or even iPhone 4s is proving to be unstable.

http://part12studios.com/temp/BloopFinal/ this is the project I'm referring too. part12studios2014-02-10 15:27:16
B
56
S
9
G
1
Posts: 938
Reputation: 6,458

Post » Mon Feb 10, 2014 4:12 pm

What is Construct 2's estimated memory use for the project? If it's way over, spritesheeting won't help.
Scirra Founder
B
387
S
230
G
87
Posts: 24,249
Reputation: 192,250

Post » Mon Feb 10, 2014 4:18 pm

approx download 35.7mb and memory use 73.1mb.   752 events
B
56
S
9
G
1
Posts: 938
Reputation: 6,458

Post » Mon Feb 10, 2014 4:19 pm

CocoonJS is horrible for handling a bigger game with lots of art, it loads everything at the start into vram which is a nightmare when you have heaps of 256 x 256 animated sprites and larger ojbects. My game with CocoonJS needs 440MB free memory to load!! This means iPhone 4 or less cannot handle it, and a lot of Android devices.

On Intel Crosswalk/XDK, it drops to ~240MB, still huge but very manageable for a lot more devices.Silverforce2014-02-10 16:36:24
B
70
S
24
G
19
Posts: 1,757
Reputation: 17,614

Post » Mon Feb 10, 2014 4:31 pm

I haven't given crosswalk a try, I should do that.
B
56
S
9
G
1
Posts: 938
Reputation: 6,458

Post » Tue Feb 11, 2014 2:46 pm

so with crosswalk i'm wondering is there a tutorial somewhere to explain how to use it? I installed the SDK and all that, but hen it says "launch service" it brings up a web page, but not the IDE itself. How do I "open" the exported project into XDK?
B
56
S
9
G
1
Posts: 938
Reputation: 6,458

Post » Tue Feb 11, 2014 2:56 pm

https://www.scirra.com/tutorials/809/how-to-export-to-android-with-crosswalk

I followed that, worked fine the first time. Once you get your project in the build menu and pick all the permissions you would like, save it, close, and relaunch, you will then get an option to build using their stable crosswalk (gold) or beta (canary). I went with canary to minimize the sound bugs (still present on some devices, but better).
B
70
S
24
G
19
Posts: 1,757
Reputation: 17,614

Next

Return to Construct 2 General

Who is online

Users browsing this forum: Yahoo [Bot] and 7 guests