Problems with Opening a PDF Document

Opening a PDF file for conversion is not the same as opening it for viewing. In some cases, efforts to secure a PDF document may prevent PDF2IMG from completing the conversion process.

If a PDF document is password protected, you will need to provide that password before PDF2IMG can work. To that end you can use the optional password command line argument, if you are using a console application.

Or you can use one of these API calls (PDF2IMG COM applications):

Also, the PDF document must be set to allow Content Copying and Page Extraction before PDF2IMG can process it.

Open the file in Adobe Acrobat and click File/Properties, and then the Security tab. Make sure that Content Copying and Page Extraction are allowed for this document.


If the Security Method for the file is set to "Password Security," as shown above, click Show Details.


The "Document Open Password" value should be set to No. This means that the file does not have a Document Open password.

If this value is set to Yes, it means that to open the PDF document you need to enter this Document Open Password, and you will need to provide this password to PDF2IMG.

PDF2IMG may be able to process a PDF document with a Permissions Password, however, depending on what Security settings are in force. You can open a PDF document without entering the Permissions Password, which is used to lock the PDF document so that the security settings for that document cannot be changed.  These settings might include the ability to print the PDF or to insert or delete pages.

If PDF2IMG cannot process a PDF document because of a security or permission problem, you will see an error message:

return code = 13, The document security settings do not permit this operation

You will need to investigate the document security or permission settings on the PDF document before continuing.

Problems with High-Resolution Conversions

Large PDF files processed at high resolution settings may cause PDF2IMG to fail; you might see a message indicating that a raster port could not be created. This typically means that there is not enough system memory available to generate raster output for the input PDF document. Rasterizing PDF documents at high resolution requires a lot of free memory.

Blurry Text Appears in Output File

When converting a PDF document with a small typeface, such as 8-point Courier, a blocky typeface with a 1-point stroke width, to TIFF output, the resulting output may appear grainy and pixelated. Some characters may develop visible gaps despite using the -smoothing command line argument.

When small text is rendered as a TIFF image without any smoothing attempts, the very narrow stroke thicknesses for the characters are dramatically affected by whether they are squarely aligned over the image pixels or not. Some legs of the glyphs will be rendered with a single line of pixels, while others will be drawn with two:


Compare the vertical strokes of the "R" and "I" characters in the upper window above. These characters have no smoothing. The R is centered over the pixel grid and uses one vertical column, while the I is straddling the grid and ends up using two columns. When smoothing is applied, as seen in the lower window, it limits this effect. If a typeface that uses bold characters or characters that are shaped differently, especially a typeface without long, straight horizontal or vertical strokes, the problem might not be visible at all, even without any smoothing.

However, if you add too many arguments to your command line statement you can make matters worse. In this case, shades of gray will be needed for effective smoothing.

While you could add a Bits per Color channel (-bpc=1) setting to the conversion, we don't recommend it.


In the images above, we see that when the Bits per Color Channel argument is set equal to 1 (-bpc=1) we lose all the gray values from the smoothing operation. The glyphs end up looking grainy and spotty as a result.

So the best configuration for each conversion depends on the details of the document you want to convert. If you want to convert a document with a fine-grained text that needs a smoothing to preserve the small type, do not alter it using the -bpc  argument. You need to preserve the gray values necessary for rendering the characters.