0

There are some pdf files.And there are pictures in PDF that are incomplete.Can i Check if PDF has incomplete pictures use ITextsharp? The Sample Pdf

The bad pdf looks like this

The bad pdf like this

Thanks a lot!

mkl
  • 90,588
  • 15
  • 125
  • 265
zhusp
  • 131
  • 12
  • are you getting this incomplete images issue while generating pdf? – Hasan Ali Nov 27 '17 at 09:22
  • The images is complete while generating pdf.Most pdf file is good,and i want to pick up the bed one. – zhusp Nov 27 '17 at 09:56
  • By looking at the screenshot you provided.I suggest you to open the pdf with chrome once and see if it still causes issue.Because sometimes pdfRaeders have issues opening files generated by itextsharp even though files are good. – Hasan Ali Nov 27 '17 at 10:40
  • For a programmatic solution you may try and use iText for image extraction. If extraction fails, images either are internally broken or the image format is not supported by iText. – mkl Nov 27 '17 at 12:30
  • It looks the same in Chrome.I‘ve tried extract images from pdf file.[Extract images using iTextSharp](https://stackoverflow.com/questions/802269/extract-images-using-itextsharp),and i got a "half" image.Is there any way to judge if the picture is complete? – zhusp Nov 27 '17 at 14:45
  • Probably by trying to load into java imageio? – mkl Nov 27 '17 at 15:11

0 Answers0