Max Schmeling
Max Schmeling

Reputation: 12509

How can I render PDF file pages as images?

I need to be able to convert a PDF file to images (one image per page) to be displayed on a web page like Google Docs does. This is for an internal intranet application where the requirements call for a PDF file on the web but with the ability to track scrolling, and this is the only way I can come up with to do it.

The problem is I can't find a good way to convert PDF files on the fly.

Upvotes: 4

Views: 8278

Answers (5)

wezten
wezten

Reputation: 2296

PeaPDF

I created a free open source project for rendering PDFs - https://github.com/elicym/peapdf/.

Ghostscript

You can also use Ghostscript, but its license is AGPL, and you will likely need to distribute your code if you use it. See https://www.ghostscript.com/license.html, especially the part:

Bottom line, if you distribute our software, or make the functionality of the software available to users interacting with it remotely through a computer network, you must share your source code.

Upvotes: 0

kwcto
kwcto

Reputation: 3504

Try GhostScript. It's open source and can by run as a command line process or directly through the DLL. I've used this in a production app for the last 2 years with minimal problems.

To see how to export images using the dll directly, see this codeproject article.

Upvotes: 10

Mark Redman
Mark Redman

Reputation: 24535

Try the PDF components from Tall Components to convert to images.

You will need to look into these a bit further to track changes etc and may require converting to text.

Upvotes: 1

Bryan Denny
Bryan Denny

Reputation: 27596

We use ABCpdf here to convert PDFs to images.

Note: it is NOT free

Upvotes: 2

user38123
user38123

Reputation: 669

You can use ImageMagik, it's free and can do that kind of conversion.

http://www.imagemagick.org

Upvotes: 1

Related Questions