syndicodefront / infekt

The ultimate best NFO viewer, ever!
https://infekt.ws/
GNU General Public License v2.0
345 stars 16 forks source link

Exported .PNG files cannot be opened in IrfanView ("Decode error, Invalid or unsupported PNG file") #123

Closed darkred closed 6 years ago

darkred commented 7 years ago

First of all, thank you for making the ultimate best NFO viewer, ever!


Using Infekt 0.9.7 x64 in win10.

I use IrfanView (a very popular image viewer) as my picture viewer, . For any .NFO I've tried to export to .PNG (File|Export|As PNG/As PNG (transparent)) -for example this NFO (please unzip)- the exported .PNG file cannot be opened in IrfanView: the following error is displayed instead Decode error, Invalid or unsupported PNG file: 2017-06-29_161428

In Windows's Photo app and Paint program (as well as Photoshop 2014 CC) it opens ok.

Related info from the IrfanView forum (link) (about 3 months ago) by the IrfanView author :

Newer IrfanView versions use a new LibPNG with strict(er) checks for buggy header and chunks. => there is a problem with the PNG header entries.

In order to avoid errors and overflows, IrfanView will stop.

So, I've made this issue here (instead of the IrfanView forum) because IrfanView is a very popular image viewer, and I've never had any issues with any image files before, so I thought that maybe something could be changed in Infekt, to make the exported .PNG files more compatible with LibPNG.

I see in the Infekt changelog that it uses LibPNG v1.6.28. I've contacted IrfanView author regarding this issue, and for the exact LibPNG version that the program currently uses (it's not mentioned in its site).

darkred commented 7 years ago

I've contacted IrfanView author regarding this issue, and for the exact LibPNG version that he currently uses in the program (it's not mentioned in his site).

He replied:

All newer LibPNG versions have stricter checks ... the version-nr doesn't matter much. Check what you write in the PNG header, no duplicate chunks