Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

what is the problem with this png image #183

Closed
sturkmen72 opened this issue Nov 2, 2017 · 4 comments
Closed

what is the problem with this png image #183

sturkmen72 opened this issue Nov 2, 2017 · 4 comments

Comments

@sturkmen72
Copy link

@sturkmen72 sturkmen72 commented Nov 2, 2017

crop_000010a

i am using OpenCV and tried to use latest version of libpng in OpenCV. i can't open the image above when i use newer versions of libpng than 1.6.25

error message libpng error: IDAT: invalid distance too far back
my OS is windows 10 64bit

@glennrp
Copy link
Owner

@glennrp glennrp commented Nov 2, 2017

As you reported, and according to "pngcheck -v" it contains the "too far back" error in the IDAT (zlib) data. You can use pngfix to repair it. pngfix comes with the libpng16 distribution, and you run

pngfix --out=problem-fixed.png problem.png

to repair it. Do you happen to know how the image was created?

Glenn

@sturkmen72
Copy link
Author

@sturkmen72 sturkmen72 commented Nov 2, 2017

thank you for the explanation

it is one of INRIA Person Dataset images ( most of them has same problem)

i can open it with libpng 1.6.25

@liquidmetal
Copy link

@liquidmetal liquidmetal commented Nov 13, 2017

Could you attach a link to the original png file? The embedded image might have gone through Github's image compression.

@sturkmen72
Copy link
Author

@sturkmen72 sturkmen72 commented Nov 13, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants