The SDL forums have moved to discourse.libsdl.org.
This is just a read-only archive of the previous forums, to keep old links working.


SDL Forum Index
SDL
Simple Directmedia Layer Forums
How to disable libpng warning: known incorrect sRGB profile
RunningOn


Joined: 23 Dec 2013
Posts: 16
My game loads PNG files, and it keeps printing 'libpng warning: iCCP: known incorrect sRGB profile', which is very annoying for debugging.
I know there must be something wrong with my PNG files. But the PNG files are not maintained by me.

I just want to disable this warning. How to do it? Thanks.
How to disable libpng warning: known incorrect sRGB profile
MrOzBarry


Joined: 26 Jun 2010
Posts: 620
Recompile libpng.  I've had that issue before and it's just a precompiled binary issue. On 19 Jul 2014 09:41, "RunningOn" wrote:
Quote:
My game loads PNG files, and it keeps printing 'libpng warning: iCCP: known incorrect sRGB profile', which is very annoying for debugging.
I know there must be something wrong with my PNG files. But the PNG files are not maintained by me.

I just want to disable this warning. How to do it? Thanks.


_______________________________________________
SDL mailing list

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

How to disable libpng warning: known incorrect sRGB profile
Jonas Kulla
Guest

If you're on Linux, install ImageMagick, then run

find . -iname "*.png" | while read f; do convert "${f}" -strip "${f}"; done



in the directory of your assets. This will fix the png's themselves.
(no warranties)



2014-07-19 15:41 GMT+02:00 RunningOn:
Quote:
My game loads PNG files, and it keeps printing 'libpng warning: iCCP: known incorrect sRGB profile', which is very annoying for debugging.
I know there must be something wrong with my PNG files. But the PNG files are not maintained by me.

I just want to disable this warning. How to do it? Thanks.


_______________________________________________
SDL mailing list

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

Re: How to disable libpng warning: known incorrect sRGB prof
RunningOn


Joined: 23 Dec 2013
Posts: 16
Where is libpng? in the source of SDL2_image?

MrOzBarry wrote:
Recompile libpng.  I've had that issue before and it's just a precompiled binary issue. On 19 Jul 2014 09:41, "RunningOn" wrote:
Quote:
My game loads PNG files, and it keeps printing 'libpng warning: iCCP: known incorrect sRGB profile', which is very annoying for debugging.
I know there must be something wrong with my PNG files. But the PNG files are not maintained by me.

I just want to disable this warning. How to do it? Thanks.


_______________________________________________
SDL mailing list

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

How to disable libpng warning: known incorrect sRGB profile
Jonas Kulla
Guest

It's not a precompiled binary issue; since version 1.6, libpng will emit these
warnings when it encounters an invalid color profile, you most likey just
compiled an older version from source instead. This annoyance is not going
to go away unless the actual png's are sanitized.

2014-07-19 15:47 GMT+02:00 Alex Barry:
Quote:

Recompile libpng.  I've had that issue before and it's just a precompiled binary issue. On 19 Jul 2014 09:41, "RunningOn" wrote:

Quote:
My game loads PNG files, and it keeps printing 'libpng warning: iCCP: known incorrect sRGB profile', which is very annoying for debugging.
I know there must be something wrong with my PNG files. But the PNG files are not maintained by me.

I just want to disable this warning. How to do it? Thanks.




_______________________________________________
SDL mailing list

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org



_______________________________________________
SDL mailing list

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

How to disable libpng warning: known incorrect sRGB profile
Sik


Joined: 26 Nov 2011
Posts: 905
libpng doesn't provide a way to have the warnings redirected somewhere
else? Forcing all that through the console is annoying.

2014-07-19 11:43 GMT-03:00, Jonas Kulla:
Quote:
It's not a precompiled binary issue; since version 1.6, libpng will emit
these
warnings when it encounters an invalid color profile, you most likey just
compiled an older version from source instead. This annoyance is not going
to go away unless the actual png's are sanitized.

2014-07-19 15:47 GMT+02:00 Alex Barry:

Quote:
Recompile libpng. I've had that issue before and it's just a precompiled
binary issue.
On 19 Jul 2014 09:41, "RunningOn" wrote:

Quote:
My game loads PNG files, and it keeps printing 'libpng warning: iCCP:
known incorrect sRGB profile', which is very annoying for debugging.
I know there must be something wrong with my PNG files. But the PNG
files
are not maintained by me.

I just want to disable this warning. How to do it? Thanks.

_______________________________________________
SDL mailing list

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org


_______________________________________________
SDL mailing list

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org



_______________________________________________
SDL mailing list

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
How to disable libpng warning: known incorrect sRGB profile
javierecf


Joined: 21 Feb 2014
Posts: 52
as far as i know you need to downgrade to a past version of libpng, but my advice would be to create a script that convert all the images to a correct format. you can use Python with PIL to do the job, or ImageMagick if available. Something like this.



2014-07-19 7:41 GMT-06:00 RunningOn:
Quote:
My game loads PNG files, and it keeps printing 'libpng warning: iCCP: known incorrect sRGB profile', which is very annoying for debugging.
I know there must be something wrong with my PNG files. But the PNG files are not maintained by me.

I just want to disable this warning. How to do it? Thanks.


_______________________________________________
SDL mailing list

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org




--
Javier Flores
How to disable libpng warning: known incorrect sRGB profile
MrOzBarry


Joined: 26 Jun 2010
Posts: 620
Huh, recompiling worked for me about a year ago, but that's interesting.  Thanks for the tip Smile


On Sat, Jul 19, 2014 at 10:43 AM, Jonas Kulla wrote:
Quote:
It's not a precompiled binary issue; since version 1.6, libpng will emit these
warnings when it encounters an invalid color profile, you most likey just
compiled an older version from source instead. This annoyance is not going
to go away unless the actual png's are sanitized.

2014-07-19 15:47 GMT+02:00 Alex Barry:
Quote:

Recompile libpng.  I've had that issue before and it's just a precompiled binary issue. On 19 Jul 2014 09:41, "RunningOn" wrote:

Quote:
My game loads PNG files, and it keeps printing 'libpng warning: iCCP: known incorrect sRGB profile', which is very annoying for debugging.
I know there must be something wrong with my PNG files. But the PNG files are not maintained by me.

I just want to disable this warning. How to do it? Thanks.




_______________________________________________
SDL mailing list

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org



_______________________________________________
SDL mailing list

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org








_______________________________________________
SDL mailing list

http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org