androidimagesizeresolutionhdpi

Android xxxhdpi drawable resolution auto resize


If I add a large image to xxxhdpi folder does it gets resized automatically by Android to smaller images for other screen resolutions?

And if yes from which version of Android is this supported?


Solution

  • Adding to my comment, this is from Android Developers - Supporting Multiple Screens.

    Provide different bitmap drawables for different screen densities By default, Android scales your bitmap drawables (.png, .jpg, and .gif files) and Nine-Patch drawables (.9.png files) so that they render at the appropriate physical size on each device. For example, if your application provides bitmap drawables only for the baseline, medium screen density (mdpi), then the system scales them up when on a high-density screen, and scales them down when on a low-density screen. This scaling can cause artifacts in the bitmaps. To ensure your bitmaps look their best, you should include alternative versions at different resolutions for different screen densities.

    And from a Roman Nurik post

    I talk about some of the key aspects of Android 4.4 KitKat that all Android designers should be aware of. Specifically:...
    7) The introduction of new XXXHDPI (640dpi) launcher icon assets due to the Nexus 5 launcher's icon scaling behavior.

    So it seems that it will scale, and that the resolution xxxhdpi is a newer implementation. I really would avoid using xxxhdpi images in an application unless you plan on using them specifically and for a good reason as they are going to be large files.

    Edit It does seem xxxhdpi was introduced in 4.3, as stated in this Android Police Article. Either way, it hasn't been around for long and isn't used by many devices at this point, so I still say that unless you have an explicit reason to use a xxxhdpi image it isn't worth the space and scaling issues you might encounter by using it.