PDF to TIFF produces blank page

conversion issues.pdf (3.1 KB)

We’ve found a problem with Aspose.PDF when converting from PDF to TIFF. This is a problem with version 22.5 and prior versions. A customer sent us a PDF file that produces an empty (all white) image. The code below will reproduce the problem, where the output is just the “Evaluation Only…” text at the top and is otherwise blank.

When SystemFontsNativeRendering is set to true the output is a blank page, setting it to false and it renders correctly. The problem here is that enabling SystemFontsNativeRendering produces better quality output for most PDF files that we encounter and I need to keep using that feature for our PDF conversions in general.

Hopefully you can work with the uploaded PDF file to get Aspose.PDF to render correctly with SystemFontsNativeRendering enabled. Thanks.

public static void ConvertPDFtoTIFF()
{
// Open document
Aspose.Pdf.Document pdfDocument = new Aspose.Pdf.Document(@“c:\aspose\conversion issues.pdf”);

// Create Resolution object
Aspose.Pdf.Devices.Resolution resolution = new Aspose.Pdf.Devices.Resolution(300);

// Create TiffSettings object
Aspose.Pdf.Devices.TiffSettings tiffSettings = new Aspose.Pdf.Devices.TiffSettings
{
    Compression = Aspose.Pdf.Devices.CompressionType.None,
    Depth = Aspose.Pdf.Devices.ColorDepth.Default,
    Shape = Aspose.Pdf.Devices.ShapeType.Portrait,
    SkipBlankPages = false
};

// Create TIFF device
Aspose.Pdf.Devices.TiffDevice tiffDevice = new Aspose.Pdf.Devices.TiffDevice(resolution, tiffSettings);

// We use this because it improves quality for most PDF to image conversions that we do
tiffDevice.RenderingOptions.SystemFontsNativeRendering = true;

// Convert a particular page and save the image to stream
tiffDevice.Process(pdfDocument, @"c:\aspose\conversion issues.tif");

}

@nickpeck

We were able to replicate the issue in our environment. Therefore, have logged it as PDFNET-51848 in our issue tracking system. We will further look into its details and keep you posted with the status of its rectification. Please be patient and spare us some time.

We are sorry for the inconvenience.