![]() Using Leadtools using Leadtools.Codecs using Leadtools.Controls using Leadtools.Pdf using Leadtools.Svg using Leadtools.WinForms public void PDFDocumentResolutionExample() ", document.Resolution, page.WidthPixels, page.HeightPixels) ' Save this page at this resolution Using image As RasterImage = document.GetPageImage(codecs, 1) codecs.Save(image, outFileName2, RasterImageFormat.Png, 32) End Using End Using ' Open both PNG files and notice that PageAt300.png has more details that PageAt150. ![]() Change the resolution of the PDF to be converted under 'File Options. Select 'Preferences' and then 'Advanced Settings' or a similar choice, depending on your version. The viewer can then obtain a new version of the image with a higher resolution by setting a new value into Resolution, such as 200, and calling GetPageImage again. Step 1 Go directly to your Acrobat toolbar if youre using a PDF-integrated Microsoft Office program or another compatible program like InDesign. When the user zooms in onto the page, a higher quality with finer details is required. For example, a PDF viewer may set Resolution to a low value, (for example, 96) and call GetPageImage to render the PDF page on the screen when the image is zoomed out and not a lot of details will be viewed. You can change the Resolution value at any time, based on what is needed. Also, the GetPageImage method will also use this resolution when calculating the page size in pixels. The PDFDocumentPage.ConvertPoint and PDFDocumentPage.ConvertRect uses the value of Resolution when converting to and from pixels. The size of the page in pixels is 1275 by 1650 - Obtained by multiplying 8.5" and 11" by 150, the current resolution The size of the page in inches is 8.5" by 11" - Obtained by dividing 612 and 792 by 72 For example, if a PDF document has a page width and height of 612 by 792 units and the resolution value set in Resolution is 150, then: Extract images from a PDF PDF to JPG Convert each PDF page into a JPG or extract all images contained in a PDF. Resolution is the value of dots (pixels) per inch to use when converting logical to physical values. To convert from logical to physical units, a resolution must be provided. Physical values such as pixels are typically needed when a PDF document is rendered to the screen. To convert a PDF unit to a physical value such as pixels you must provide an external value for the resolution. Instead, all locations and sizes are stored in PDF units which are equivalent to 1/72 of an inch. High resolution values will render the document with greater detail at the expense of using more system resources. If the image is the same and you're happy with the results, then the issue was probably only the resolution preview in Acrobat.Īcrobat doesn't always show images, texts and vector in a perfect way, and there's a few settings in your preferences that don't affect the file but still display them differently than in a software like Photoshop.A value of 0 means, "Use the current screen resolution" (usually, 96 DPI). If you aren't sure if your Acrobat is doing a good job, simply open a few of these PDF in Photoshop at their native resolution. Maybe that's what you're referring to in your question and you already verified this. You can also have a look at the PNG to PDF conversion preferences by default they seem to be at medium quality. ![]() So it's worth trying a different setting that fits your screen. It's possible this is what makes the images look lower resolution. If you use 72ppi then it should show you the images as they truly are. If you use the default setting, it might show your image bigger when viewing at 100%. To come back on your issue of Acrobat lowering the quality of your PNG: One thing you might want to verify is the resolution of your Acrobat preferences. If you expect a different page size or would prefer a higher resolution and smaller size, you'll probably need to resave your PNG with a higher resolution or maybe have a look at the preflight functionality of Acrobat Pro to modify the resolution quickly within the PDF. Your PNG are low resolution and Adobe Acrobat simply take what you have and doesn't modify them. The question is: What page size do you expect? The page size (16.81 x 20.14 in.) is exactly the number of pixels at 72 ppi.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |