Analyze format of pdf-file and extract text and images [closed]
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 5 years ago.
开发者_如何学编程 Improve this questionI need to extract the "articles" from this magazine which has both text and images. The image content has to be placed separately, the text extracted (as far as possible) and placed separately.
How do i go about doing this? Is there a commercial service / api that does this already? The input to the program/service will just be the file.
Eg of input: http://edition.pagesuite-professional.co.uk/pdfspool/rQBvRbttuPUWUoJlU6dBVSRnIlE=.pdf
(the actual file would be a normal pdf-file, not a seured one)
Docotic.Pdf library can extract images and text from PDF files for you.
Here are couple of samples for your task:
- Extract text from PDFs
- Extract images from a PDF
Extracted images can be saved as JPEG and TIFFs. You can extract text from each page or from the whole document. And you can extract text chunks with their coordinates.
Disclaimer: I work for Bit Miracle, vendor of the library.
Try this one:
http://asp.syncfusion.com/sfaspnetsamplebrowser/9.1.0.20/Web/Pdf.Web/samples/4.0/Importing/TextExtraction/CS/Default.aspx?args=7
The same component has the image-extraction feature also.
You could make a try!!
If you can afford a commercial option, Amyuni PDF Creator will allow you to enumerate all components inside the pdf file (text, image, etc), you will be able to extract them as independent objects and you can create new PDF files with them.
You may use Aspose.Pdf.Kit to extract text and images separately from a PDF file. The API is quite simple. You can also find samples, tutorials and support on Aspose website.
Note: I'm working as Developer Evangelist at Aspose.
精彩评论