PdfConvertor Image quality

Last post 01-16-2012, 4:46 AM by aspose.notifier. 4 replies.
Sort Posts: Previous Next
  •  07-27-2011, 9:49 AM 318857

    PdfConvertor Image quality .NET

    Hi,

    One of the things we want to use your library for is to create previews of  various file formats. I have created 300px (width or height) previews using Words, Cells and Slides with good results. Using PdfConverter to create images works but is far poorer quality at the same resolution. Why is this and is there a better alternative for a pdf preview?

    Sample code:
    PdfConverter pdfConvertor = new PdfConverter();
    pdfConvertor.BindPdf(filePath);
    pdfConvertor.DoConvert();

    pdfConvertor.GetNextImage(outPath, ImageFormat.Jpeg, (float)previewSize.Width, (float)previewSize.Height, imageFormat.JPEGQuality);
     
  •  07-28-2011, 1:06 AM 318992 in reply to 318857

    Re: PdfConvertor Image quality

    Hi Jai,

    Please set the Resolution property of the PdfConverter class. The default value is 150, however you may set higher values to see if it produces the output of required quality. However, please note that higher the resolution lower the conversion speed. If it still doesn't resolve your issue then please share the input PDF file with us, so we could investigate the issue at our end.

    We're sorry for the inconvenience.
    Regards,

    Shahzad Latif - [Follow me on Twitter!]
    Support Developer/Developer Evangelist
    Aspose Sialkot Team
    Aspose - Your File Format Experts

    Keep in touch! We're on Twitter and Facebook
     
  •  07-28-2011, 3:12 AM 319041 in reply to 318992

    Re: PdfConvertor Image quality

    Attachment: Present (inaccessible)
    Hi Shahzad,

    Thanks for your response but I refer to the comparable quality at the same resolution. For example creating a 212*300 jpg A4 preview of the same document saved in both Word and PDF format, the Aspose.Words.Document.Save() does a far better job than PdfConvertor.GetNextImage().

    What I have found is that an image created with width or height below about 600px is poor. Above this it's acceptable. As a workaround I create an image using GetNextImage() with width or height about 1000px and then open the image using System.Drawing.Image and reduce it's size. Ideally having to reopen the image to rescale wouldn't be necessary.

    Attached are the Word and PDF originals and images created from both.
     
  •  07-29-2011, 1:30 AM 319289 in reply to 319041

    Re: PdfConvertor Image quality

    Hi Jai,

    I have reproduced the problem at my end and logged it as PDFNEWNET-29470 in our issue tracking system. Our team will look into this issue and you'll be updated via this forum thread once it is resolved.

    We're sorry for the inconvenience.
    Regards,

    Shahzad Latif - [Follow me on Twitter!]
    Support Developer/Developer Evangelist
    Aspose Sialkot Team
    Aspose - Your File Format Experts

    Keep in touch! We're on Twitter and Facebook
     
  •  01-16-2012, 4:46 AM 355368 in reply to 318857

    Re: PdfConvertor Image quality

    The issues you have found earlier (filed as PDFNEWNET-29470) have been fixed in this update.


    This message was posted using Notification2Forum from Downloads module by aspose.notifier.
     
View as RSS news feed in XML