We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

PDF to tiff performs very slowly

Hello,

I am having a performance issue converting PDF documents to Tiff. For example, a simple 7 page pdf that contains mostly text a page header that has a graphic, it takes about 6 second to save as a single multiple image tiff file.

I have tried imaging the pdf using the TiffDevice and the pdfConverter examples that aspose provides and also tried using the IIndexBitmapConverter as per this link with no luck:

https://docs.aspose.com/display/pdfnet/performance+improvement+during+pdf+to+tiff+conversion

I am using the latest version of aspose.pdf and I have tried adjusting the tiff settings and resolution without much change in performance

Here is a example of how I am converting the pdf to tiff:

        Document pdf = new Document(@"d:\input\simple.pdf");
        var resolution = new Resolution(300);
        TiffDevice tiff = new TiffDevice(resolution, settings);
        TiffSettings settings = new TiffSettings()
        {
            Compression = CompressionType.CCITT4,
            Depth = ColorDepth.Format8bpp,
            SkipBlankPages = false,
            Shape = ShapeType.Portrait
        };
        var tempFile = string.Format(@"d:\output\pdf.tif");
        tiff.Process(pdf, tempFile);

Has anyone else seen this issue or have a suggestion to improve performance?

@ejt66

Thanks for contacting support.

Would you please share your sample document with us, so that we can test the scenario in our environment and try to experience the same performance of the API with specific document, which you are observing.

Here it is, it’s a sample document that I found online and tested with. It took nearly 6 seconds to image this to tiff using:

        TiffSettings settings = new TiffSettings()
        {
            Compression = CompressionType.CCITT4,
            Depth = ColorDepth.Format8bpp,
            SkipBlankPages = false,
            Shape = ShapeType.Portrait
        };

        Document pdf = new Document(file);
        var resolution = new Resolution(300);

        TiffDevice tiff = new TiffDevice(resolution, settings);

        var tempFile = string.Format(@"d:\output\single.tif");

        tiff.Process(pdf, tempFile);

example.pdf (1.3 MB)

@ejt66

Thanks for sharing sample document.

I have tested the scenario in our environment and managed to observe that API was taking ~8 minutes to process the conversion. Hence, have logged an investigation ticket as PDFNET-43216 in our issue tracking system. We will further investigate this and keep you updated with the status. Please be patient and spare us little time.

We are sorry for this inconvenience.

@ejt66

Thanks for your patience.

We are pleased to inform you that earlier reported issue PDFNET-43216, has been resolved in latest version Aspose.Pdf for .NET 17.11. While testing with latest version, API took ~2 seconds for conversion. Please try using the latest release version and in case you face any issue, please feel free to contact us.