Android icon generator for actionbar and notification not working (grey shape)

32,955

Solution 1

You can use a tool for creating generic icons in Asset Studio: https://romannurik.github.io/AndroidAssetStudio/icons-generic.html. To get it look like ActionBar Icon, you should make next actions:

  1. Choose image
  2. The size of image should stay at 24dip
  3. Change padding to 4dip
  4. Move foreground color thumb to 0%
  5. That's it! Download .zip now.

The sizes of icons will be pretty the same as you can get them with ActionBar Icon Generator.

How it looks for me: icon generator screenshot

Solution 2

I think it's because your image is too complexe and the main problem is the "color" filter applied in AAS.

I had the same problem and I had to convert xxxhdpi xxhdpi etc. manually. If you work with Sketch (for example) it can be converted easily with a plugin (https://github.com/zmalltalker/sketch-android-assets)

hope it's help !

If you want to use AAR, like @rom4ek explained "4. Move foreground color thumb to 0%" this is the important part

Solution 3

Use this instead https://romannurik.github.io/AndroidAssetStudio/icons-generic.html

Here demonstrating how to show the image:

  1. upload your image
  2. set the foreground color to 0, just like below

Thanks to https://stackoverflow.com/users/3225458/romtsn enter image description here

Solution 4

I use an own module 'icons' with a Gradle script to generate icons. This is a more automated way than the Assets Studio can provide up-to-now. The icon will be designed with Inkscape. See my blog for a detailed description. You find an Android Studio Project on GitHub.

Share:
32,955
Mulgard
Author by

Mulgard

Updated on September 19, 2021

Comments

  • Mulgard
    Mulgard over 2 years

    I found this Asset Studio to generate icons. It works fine for the launcher icon but for action bar or notification icons it is not working. I put in my png file and want to generate the icons, but Asset Studio is only generating gray circles. Is there another tool to generate action bar and notification icons?

    enter image description here