2

Hello I have a list of similar error after I've updated from sdk manager.

AAPT err(1212957672): C:\Users\Test\Documents\spark-Android\app\src\main\res\drawable-hdpi\bin.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited AAPT err(1212957672): C:\Users\Test\Documents\spark-Android\app\src\main\res\drawable\logo.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited AAPT err(582622936): C:\Users\Test\Documents\spark-Android\app\build\intermediates\exploded-aar\com.github.navasmdc\MaterialDesign\1.5\res\drawable-xhdpi-v4\sprite_check.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited AAPT err(70038626): C:\Users\Test\Documents\spark-Android\app\src\main\res\drawable\certifi_logo.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited AAPT err(1121607700): C:\Users\Test\Documents\spark-Android\app\src\main\res\drawable-hdpi\certifi_logo.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited AAPT err(87695913): C:\Users\Test\Documents\spark-Android\app\src\main\res\drawable-ldpi\create_defalit_yellow.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited AAPT err(87695913): C:\Users\Test\Documents\spark-Android\app\src\main\res\drawable-mdpi\create_defalit_yellow.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited AAPT err(826611364): C:\Users\Test\Documents\spark-Android\app\src\main\res\drawable-hdpi\create_defalit_yellow.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited AAPT err(1235952614): C:\Users\Test\Documents\spark-Android\app\build\intermediates\exploded-aar\com.github.navasmdc\MaterialDesign\1.5\res\drawable-hdpi-v4\sprite_check.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited AAPT err(1475258342): C:\Users\Test\Documents\spark-Android\app\src\main\res\drawable-mdpi\logo.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited AAPT err(1475258342): C:\Users\Test\Documents\spark-Android\app\build\intermediates\exploded-aar\com.github.navasmdc\MaterialDesign\1.5\res\drawable-ldpi-v4\sprite_check.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited AAPT err(1475258342): C:\Users\Test\Documents\spark-Android\app\src\main\res\drawable-ldpi\bin.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited AAPT err(695446339): C:\Users\Test\Documents\spark-Android\app\src\main\res\drawable-hdpi\logo.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited AAPT err(400880582): C:\Users\Test\Documents\spark-Android\app\src\main\res\drawable-mdpi\bin.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited AAPT err(20049084): C:\Users\Test\Documents\spark-Android\app\build\intermediates\exploded-aar\com.github.navasmdc\MaterialDesign\1.5\res\drawable-xxhdpi-v4\sprite_check.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited AAPT err(317875595): C:\Users\Test\Documents\spark-Android\app\src\main\res\drawable-ldpi\certifi_logo.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited AAPT err(713069587): C:\Users\Test\Documents\spark-Android\app\build\intermediates\exploded-aar\com.github.navasmdc\MaterialDesign\1.5\res\drawable-mdpi-v4\sprite_check.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited AAPT err(627427343): C:\Users\Test\Documents\spark-Android\app\src\main\res\drawable-ldpi\logo.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited AAPT err(627427343): C:\Users\Test\Documents\spark-Android\app\src\main\res\drawable-mdpi\certifi_logo.png: libpng warning: iCCP: Not recognizing known sRGB profile that has been edited

LittleFunny
  • 8,155
  • 15
  • 87
  • 198

2 Answers2

2

According to Android Studio: "libpng warning: iCCP: Not recognizing known sRGB profile that has been edited", here's an answer:

It's just a warning, which libpng started issuing at version 1.6.0, so you can ignore it.

To get rid of the warning, you need to fix the PNG file that's named in the warning. You can use any one of a number of PNG image editors (ImageMagick, GraphicsMagick, etc.) to remove the offending iCCP chunk. Or you can downgrade your libpng to version 1.5.x.

See the similar question libpng warning: iCCP: known incorrect sRGB profile

You can use ImageOptim with those listed image files to get rid of that warning and remove: junk metadata and unnecessary color profiles.

Hope it help

Community
  • 1
  • 1
piotrek1543
  • 19,130
  • 7
  • 81
  • 94
  • I made my buildtool to 22.0.0.1 and it works fine... If I used ImageOptim, i can modify my own image but any android native or libraries' images I can't edit them – LittleFunny Dec 28 '15 at 01:32
0

As explained in the libpng man page, you can include this in your own application to suppress the warnings about invalid sRGB profiles:

#if defined(PNG_SKIP_sRGB_CHECK_PROFILE) && \
    defined(PNG_SET_OPTION_SUPPORTED)
   png_set_option(png_ptr, PNG_SKIP_sRGB_CHECK_PROFILE,
       PNG_OPTION_ON);
#endif

If you can't edit either the PNG files or the application source code, then you will just have to downgrade libpng to 1.5.x or ignore the warnings (or complain to your upstream supplier of application and images).

Glenn Randers-Pehrson
  • 11,940
  • 3
  • 37
  • 61