Reputation: 159
I'm having an annoying issue with the launcher icon
of my app. It seems to be too small. So, it is definitely smaller than all the other icons on my phone.
So, I just created my icon with a size of 512x512 pixels. Then in Eclipse, in my project, I chose New > Android Icon Set
, then I clicked next
and then I clicked on Image
to choose my icon. After, I set a tick in the checkbox called "Trim Surrounding Blank Space"
. "Additional Padding"
have I set to 5%, "Foreground Scaling"
to "Center"
and the Shape
to "None"
. Then I clicked on finish
. Eclipse created then the icons to all the correct sizes (48x48 in mdpi, 72x72 in hdpi and so on). Then I let my project run on my ADV and after I installed in on my phone. But the icon was just too small.
I have also gooled after some solutions and found "Android Asset Studio"
which is a web application to generate icons.
Android Asset Studio: http://android-ui-utils.googlecode.com/hg/asset-studio/dist/index.html
I clicked on "Launcher icons"
and did the same steps as I did in Eclipse. But unfortunately without any avail. So, I installed my app with new icon on my phone. The result, the icon was still too small.
I also had a look at similar questions here but no answer has sloved my issue.
Maybe you can help me, please?
I'm looking forward to your help!
If you need any more information, just tell me because I have no Idea where the issue could be.
Thanks in advance!
Upvotes: 0
Views: 2471
Reputation: 3152
I found when I created:
the image resolutions at 160px - 640px resolution
change the "print size" (I'm using Gimp) to the 48px - 192px respectfully (while leaving the resolution intact)
import all those different files into all my appropriately sized drawables folders
change the Android Manifest to an ic_launcher_name_xxhdpi (my folders didn't have xxxhdpi)...
then it automatically takes the right size you need, even though they are all different files in there with different names and different sizes. Score!
Specifications are in Android Iconography.
Upvotes: 0
Reputation: 38098
Be sure to read this reference page.
Then, in each drawable folder put te corresponding icon, at the proper resoution in dpi.
Unfortunately, Eclipse itself and the Asset Studio produce ion at 72 dpi for each size!!
This will produce weird results
Please note that dpi measures the RESOLUTION, not the SIZE of an image.
resolution != size;
dp (or dip) relate to dpi, of course, but are a different beast.
They serve the purpose of scaling pixels according to the correct dpi resolution.
Now, your mdpi graphics SHOULD REALLY BE SAVED AT 160 dpi, not 72 dpi.
And ldpi at 120 dpi, and hdpi at 240 dpi... and so on.
72 dpi really don't suffice - not for my tastes.
Upvotes: 2