1
\$\begingroup\$

I am developing an Unity game for a wide range of iOS devices. I noticed that some scenes load pretty fast in the iPad mini 3, but very slow in the iPad mini 1. Of course, that's to be expected as one is much faster than the other.

The scene is composed mostly of several sprites. As an optimization attempt, one could reduce the max texture size property of the sprites, as I'd imagine this will allow them to load faster.

Is it possible to have a max size of 2048 for the iPad mini 3, but only 1024 for the iPad mini 1?

I suspect that the answer is no, as Unity "compiles" the images depending on the settings you used when building the game.

\$\endgroup\$
1
  • \$\begingroup\$ Essentially you're wanting to ask unity to include two versions of the texture rather than relying on mipmaps. So why not just do that yourself setting one to 2048 and the other to 1024. Then programmatically pick the texture in Start() based on the device? I guess it's the issue of sprites. Not sure how you'd do that without having doubles of all those also. \$\endgroup\$
    – badweasel
    Commented Jan 27, 2015 at 12:56

1 Answer 1

2
\$\begingroup\$

One way I'd go about is to set all textures in your materials to the smaller version for fast loading, and in the Resource folder (http://docs.unity3d.com/ScriptReference/Resources.html) you put the higher resolution versions with matching names ("Dirt" -> "Dirt_HD").

Then on devices that can handle it you have a script in your game that go through all the materials and load the HD version of all its textures, replacing them in all the materials.

Make sure you use a dictionary to only load each texture once when multiple materials share the same texture.

And call Resources.UnloadUnusedAssets() to unload the low resolution versions.

\$\endgroup\$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .