Tiled Backgrounds and Ejecta

Ideas and discussion about publishing and distributing your games

Post » Fri May 09, 2014 8:17 am

My app runs with excellent performance after publishing for iOS via Ejecta, but my tiled background images do not appear in the published app. The backgrounds show up as completely white instead. They load normally in the Xcode simulator, but not after publishing as a native app.

Do either Ejecta or iOS have issues with C2's tiled background object or would they otherwise have issues loading images or tiled backgrounds with large dimensions? My tiled background images have dimensions of 1x1536, which I realize is quite large, but it allows me to cover an entire iPad-sized screen with a full gradient and hasn't created issues when exporting for any other platform (these images are each under 4 KB, by the way).

Any other ideas on what would cause my tiled backgrounds not to appear in a native iOS app after publishing via Ejecta?

As a side note, publishing via Ejecta raised my app's file size from less than 1 MB to 9.8 MB (Intel XDK is even worse in this regard, fattening my app to 17 MB). Are there any settings I can adjust to help lower the file size or would I have to rely on future updates to Ejecta/Intel XDK to solve this?
B
5
S
2
G
3
Posts: 16
Reputation: 1,007

Post » Fri May 09, 2014 10:59 am

That's an extreme size for a tiled background, and many mobile systems will force it to be a power-of-two size in memory, so every 1x1536 image will use up a 2048x2048 surface (16mb of memory alone). Perhaps your project is running out of memory so later images fail to load. I'd really avoid such extreme dimensions on objects.
Scirra Founder
B
397
S
236
G
88
Posts: 24,423
Reputation: 194,560

Post » Fri May 09, 2014 4:59 pm

Strangely, it's only the native iOS app that has a problem loading these tiled backgrounds. When using Safari and running the app as an HTML5 Website the tiled backgrounds load immediately on the same iOS device. What would account for the difference?

If it's best to use power of 2 tiled backgrounds with smaller dimensions, how can I achieve a screen-wide gradient like this...

Blue Gradient.png


I'd prefer to use backgrounds that smoothly transition from a darker shade at the top to a lighter shade at the bottom and cover the whole layout, but I'm not sure how to get the same effect without using a tiled background with huge dimensions.
You do not have the required permissions to view the files attached to this post.
B
5
S
2
G
3
Posts: 16
Reputation: 1,007


Return to Distribution and Publishing

Who is online

Users browsing this forum: No registered users and 2 guests