What's the correct size icon for drawable-xxhdpi?

后端 未结 4 1772
时光取名叫无心
时光取名叫无心 2020-12-02 04:50

As we know, the correct sized icon:

* drawable-ldpi (120 dpi, Low density screen) - 36px x 36px
* drawable-mdpi (160 dpi, Medium density screen) - 48px x 48p         


        
4条回答
  •  天命终不由人
    2020-12-02 05:04

    This is a quote from a post on Google Plus https://plus.google.com/118292708268361843293/posts/ePQya3KsTjW by Nick Butcher

    The gorgeous screen on the Nexus 10 falls into the XHDPI density bucket. On tablets, Launcher uses icons from one density bucket up [0] to render them slightly larger. To ensure that your launcher icon (arguably your apps most important asset) is crisp you need to add a 144*144px icon in the drawable-xxhdpi or drawable-480dpi folder.

    So, for the xxhdpi qualifier, you will need to create an icon of the size 144*144px for your launcher icon. You can either place it in the drawable-xxhdpi or the drawable-480dpi

    EDIT: To add to the original answer to address cone of the comments by the OP.

    As per this link: http://developer.android.com/guide/practices/screens_support.html#DesigningResources, alternative resources should be created using this ratio: 3:4:6:8 scaling ratio. However, if you are concerned about loosing quality with regards to your in-app drawable resource, consider using 9-patch images wherever possible. That will reduce or eliminate any loss of quality. The Android OS all by itself, does a remarkable job handling various screen sizes most of the time anyway.

    As for the icon size 144*144px, create either of these two folder drawable-xxhdpi or the drawable-480dpi and place just your launcher icon of the said size in it. That should do it.

提交回复
热议问题