- Home /
Issues with mipmap icons
Hi all,
I got a mail from Google which stated
The app must have a xxxhdpi (192 x 192 px) launcher icon so that the newest class of devices with high-density displays are best supported. Please note that launcher icons should be placed in /res/mipmap-[density]/ folders and set android:icon="@mipmap/app_icon" in manifest file as outlined in the following: http://developer.android.com/guide/practices/screens_support.html#support
How can I generate the mipmap icons ?
I am also facing the same problem (email from Google as well). I have tried modifying my Android$$anonymous$$anifest.xml but it seems adding @mipmap in the tag is not working. $$anonymous$$odifying permissions in the Android $$anonymous$$anifest does work but maybe when Unity generates @drawable it overwrites @mipmap? The other idea I had was to export to an Android Studio project to get more control over the build process but that lead to other problems with plugins having the same class name (which does not happen if I build in Unity).
Answer by tkamruzzaman · Dec 14, 2016 at 07:58 AM
Step 01: Replace 'drawable' with 'mipmap' in main AndroidManifest.xml (Assets\Plugins\Android)
<supports-screens android:smallScreens="true" android:normalScreens="true" android:largeScreens="true" android:xlargeScreens="true" android:anyDensity="true" />
<application android:icon="@mipmap/game_icon" android:label="@string/app_name" android:debuggable="true">
Step 02: Make a folder called 'res'. Make six sub folders 'mipmap-ldpi', 'mipmap-mdpi', 'mipmap-hdpi', 'mipmap-xhdpi', 'mipmap-xxhdpi', 'mipmap-xxxhdpi' and put respective dpi icons in them and renamed them 'game_icon'.
Note:
a) From the PlayerSettings's icon Uncheck the 'Override for Android' checkbox.
b) Icon per folder should have following sizes:
mipmap-ldpi = 36*36
mipmap-mdpi = 48*48
mipmap-hdpi = 72*72
mipmap-xhdpi = 96*96
mipmap-xxhdpi = 144*144
mipmap-xxxhdpi = 192*192
This worked for me but I had to modify my manifest file that is located in my Unity installation at C:\Program Files (x86)\Unity\Editor\Data\PlaybackEngines\androidplayer ins$$anonymous$$d.
Your answer
Follow this Question
Related Questions
Assign gameobject icon dynamically 0 Answers
Why is this error occuring and how to resolve it ? please help !! 1 Answer
Mipmaps don't get blur on iOS 0 Answers
How can I turn off gameobjects icons in camera view? 0 Answers
Why won't my UI script work? 1 Answer