my app was killed,and the log :libpng warning: Ignoring bad adaptive filter type. I want to know the reason,and the solution.
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
The question gives insufficient information to provide a complete answer.
The "bad adaptive filter type" message means that the PNG file is either corrupted or was generated by a buggy encoder.
Each scanline of a PNG file begins with a "filter type" byte which must be 0, 1, 2, 3, or 4.
回答2:
I had this issue before, the image was corrupted by unknown reason, the solution of catching such an error can be using the code below (in Python):
try:
Image.open(path).tobytes()
except IOError:
print('detect error img %s' % path)
continue