There seems to be an Android Cooking issue with 4.9 build. While cooking a project which has already been cooked, packaged and run successfully on all previous versions of Unreal Engine (4.3 - 4.8), I encountered the following error:
LogImageWrapper:Error: PNG Error: IDAT: CRC error
I tried different compression ETC1, ETC2, ASTC, ATC and the same issue. However the same content on 4.9 builds fine for iOS!
I have updated the Android SDK, and still get the error. The Irony is that we have not even imported any PNG into our project as far as I know. All our source images are TGA.
I tried a simple third person game on Android, and it works fine. I was wondering if anyone else encountered the same problem?
From the error is seems there is a corrupted PNG file. It could be from a material your project is referencing which is corrupt in the project or maybe in the engine materials. Do you have a full log? It is likely the material will be listed right before this error during the cooking phase.
As I mentioned in the original post, we have not used any PNG in this project. All our source files are TGA. I don’t think any of our materials is corrupted, since the same project with the same assets was building just fine on 4.8.3. Different people build this on 4.9 on different machines downloading engine differently, so I doubt that the corrupt engine material is the issue either. (Unless, there is a corrupted PNG file as part of 4.9 download.)
The material which will be listed right before the error is different each time. I even tried to delete that material, or replace it, but the error will show up on some other material.
Here are two different logs, and as you can see it gives the error on the different file each time:
The error message is definitely coming from the png reader. If you are using GitHub sources, you can try adding a breakpoint in Engine/Source/Developer/ImageWrapper/Private/PngImageWrapper.cpp in FPngImageWrapper::user_error_fn(). The callstack should help track down where the png is coming from.
Thanks for the hint Chris. It seems the crash happens on a material related to a particle, and I can see that source file is actually a PNG. Hopefully replacing that will resolve the issue!
I am having the same error after going from 4.18 to 4.19 and the recommended solution of deleting intermediate and saved folder contents and recompiling did not work for me. I have also tried deleting the referenced assets from the project and re-adding them from the marketplace and that did not work either. I’m very much trying to avoid fine tooth combing the entire project and exporting every PNG file and then reimporting as that will take a very long time.