I have an image which is about 2mb in size and I want to use it as a background for my app.My question is, will this image add 2mb to the game's size (like for example the game is 20mb and after adding the image it will be 22mb) or will it get reduced when I add it to my app? I am using Unity by the way.

  • 1
    \$\begingroup\$ Did you try it? \$\endgroup\$ – Vaillancourt Dec 15 '16 at 16:53
  • \$\begingroup\$ @AlexandreVaillancourt No \$\endgroup\$ – Casanova Dec 15 '16 at 16:56
  • \$\begingroup\$ Well, if you insert 2mb of information, what do you think will happen? The information has to be somewhere. You could try changing the image's format, maybe to something loosy if you don't need an exact copy. \$\endgroup\$ – rlam12 Dec 15 '16 at 16:58
  • 1
    \$\begingroup\$ I believe you would have had the answer in like 2 minutes if you just tried it on your app \$\endgroup\$ – realUser404 Dec 15 '16 at 17:06
  • 2
    \$\begingroup\$ Down voting for the clear lack of research. Common sense should answer this. Testing on a blank app should answer this. \$\endgroup\$ – Gnemlock Dec 15 '16 at 20:43

This will, of course, add some data to the app. However the actual APK may not increase by exactly the size of that image. It may be compressed with other files to mean that its slightly smaller.

If you're worried about the size of images in your app, you should consider using vector images, images that are made of drawing instructions instead of raw pixel data (yes I know most image formats aren't very close to raw pixel data at all), this can mean thta many images can be much smaller file sizes, this however doesn't work for things like real world photographs, which can be larger file sizes than traditional images. Vector formats also have the advantages of scaling to fit many resolutions without looking terrible.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.