libpng warning:iCCP:known incorrect sRGB profile


 

原因是新版的libpng增強了檢查,發出警告。此警告可以忽略。
若要消除此警告則要使用v4的色彩配置。
GIMP sRGB v4 色彩配置,修改當前圖片的色彩配置,設為默認。

sRGB profiles
On this page you will find several different types of sRGB profiles, with information about their intended use.

sRGB v4 Preference
sRGB v4 Appearance
sRGB v2

sRGB v4 Preference
The sRGB v4 ICC preference profile is a v4 replacement for commonly used v2 sRGB profiles. It gives better results in workflows that implement the ICC v4 specification. It is intended to be used in combination with other ICC v4 profiles.
The advantages of the new profile are:
More pleasing results for most images when combined with any correctly-constructed v4 output profile using the perceptual rendering intent.
More consistently correct results among different CMMs using the ICC-absolute colorimetric rendering intent.
Higher color accuracy using the media-relative colorimetric intent.
A typical use case would be to print sRGB images captured with a digital still camera. In this case a user could open the image in Adobe® Photoshop®, assign the sRGB v4 profile as shown in Figure 1. Adobe® Photoshop® is either a registered trademark or trademark of Adobe Systems Incorporated in the United States and/or other countries.

 

 

解決方法:

下載ImageMagick:https://imagemagick.org/script/download.php#windows

然后將圖片打開再另存即可。

 

批量執行

也可以通過腳本轉換,同樣需要上面的工具,注意將fn的值修改為程序安裝的路徑

@echo off
echo ImageMagick fix libpng warning: iCCP: Not recognizing known sRGB profile ......
echo Search PNG in subdirs and process ...
set fn=C:\soft\ImageMagick-7.0.8-Q16\convert.exe
for /f "tokens=*" %%i in ('dir/s/b *.png') do "%fn%" "%%i" -strip "%%i"
pause

然后將該bat腳本放在圖片目錄下

雙擊執行即可

所有圖片就已經替換完畢了!

 

 

參考:

https://www.cnblogs.com/Esperanto/p/8044032.html

https://zhidao.baidu.com/question/1175819353197087339.html

https://blog.csdn.net/u010212648/article/details/82191419

https://blog.csdn.net/chan_qx/article/details/53929727

https://imagemagick.org/script/download.php#windows

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM