brumbrum brumbrum - 1 year ago 149
iOS Question

<Error>: ImageIO: PNG invalid PNG file: extra chunks between iDOT and IDAT

Just got this funny looking error in my swift project debugger.

There is probably an invalid name of an image somewhere, but I am not sure what

extra chunks between iDOT and IDAT
mean.

Do you have any idea what causes it?

Answer Source

This issue is completely random and happened to me too with a few images. Probably another Xcode bug.

  1. My image is called "back2@2x.png"
  2. I renamed it to "back2.png"
  3. Ran the project (the image will appear stretched)
  4. Changed it back to "back2@2x.png"
  5. Ran project
  6. FIXED?!

Good-luck hope it helps!