Quantcast
Channel: Questions in topic: "ios"
Viewing all articles
Browse latest Browse all 4709

Best way to handle loading textures based on device?

$
0
0
I am working on an iOs app that will be extended to Android. I'm using NGUI to create a resolution independent interface. At runtime, I load the appropriate textures for that device from the Resources folder. For example: Resources/iPad Retina/logo_texture_ipad_retina.png Resources/iPad/logo_texture_ipad.png Resources/iPhone 5/logo_texture_iphone5.png Resources/iPhone 4/logo_texture_iphone4.png This all works but with so many textures in the Resources folder, my app is HUGE. I'm wondering what the best practice is to keep app size down and only build textures that are necessary for a device. For example, if the user is on an iPad 3, the only folder that needs to exist is Resources/iPad Retina/. The other folders are not used. Is this what Asset Bundles are for? Create an Asset Bundle for each device? I'd prefer the user doesn't have to download all the textures when the app runs. If downloading an Asset Bundle is the way to go, does caching make it a one-time thing? Is this a common practice? Thanks

Viewing all articles
Browse latest Browse all 4709

Trending Articles