December 7, 2020 | Formats, Tutorial

Convert PDF, Documents, and Images to TIFF


Illustration for the blog article about TIFF conversion

The TIFF format

TIFF or TIF (Tagged Image File Format) is a raster image format standard.
Its structure can describe image data in grayscale, color palette, and in other cases, color in various color spaces.

It is perhaps the most versatile and diverse bitmap format in existence. Its extensible nature and support for numerous data compression schemes allow developers to customize the TIFF format to any peculiar data storage needs.

For more information about the TIFF format, check our blog article on the ORPALIS website .

A brief history

Created in 1986 by Aldus Corporation, the TIFF format was developed based on feedback from scanner manufacturers and software developers. Its main objective was to provide a standard for raster files of scanned images for all scanner suppliers.

Later, it introduced support for grayscale and color.

In 1988 version 5.0 was released with support for color palette images and LZW compression.

The last version of the TIFF format is from 1992 (!) and includes support for CMYK and YCbCr color images, and the JPEG compression method.
In 1994 Adobe Systems acquired Aldus and maintains the specification since.

The GdPicture.NET Document Converter

The GdPicture.NET SDK includes the GdpictureDocumentConverter class, which provides many different methods and properties for document conversion of 100+ document/image formats.

Now, let’s see how to convert any supported format to a .tiff file:

C#
using (GdPictureDocumentConverter gdpictureDocumentConverter = new GdPictureDocumentConverter())
{
    GdPictureStatus status = gdpictureDocumentConverter.LoadFromFile("drawing.pdf", GdPicture14.DocumentFormat.DocumentFormatPDF);
    if (status == GdPictureStatus.OK)
    {
        gdpictureDocumentConverter.RasterizationDPI = 300;
        status = gdpictureDocumentConverter.SaveAsTIFF("drawing_image.tiff", TiffCompression.TiffCompressionAUTO);
        if (status == GdPictureStatus.OK)
        {
            MessageBox.Show("The file has been saved successfully.""GdPicture");
        }
        else
        {
            MessageBox.Show("The file has failed to save. Status: " + status.ToString(), "GdPicture");
        }
    }
    else
    {
        MessageBox.Show("The file has failed to load. Status: " + status.ToString(), "GdPicture");
    }
}

Do not forget to use the GdPictureStatus enumeration to have a following of your process and get potential errors.

As you can see in this example, we took as input a PDF, but you can select another format by just changing the path and the GdPicture14.DocumentFormat.DocumentFormatPDF in the « LoadFromFile » method.

GdPictureDocumentConverter provides two ways of saving your document as a TIFF:

You can also change properties of your conversion in order to select the range of pages you want to convert, the amount of DPIs, if you want to keep or not the annotations within the converted document, and more.
For example, this is how you change the DPIs of the output TIFF:

gdpictureDocumentConverter.RasterizationDPI = 300;

You will find all the properties here.

If you wish to learn more about the GdPicture.NET Document Converter, you will find everything you need in our documentation.

And if you want to test our PDF to TIFF converter in real time, there is our online tool:

Cheers!

Fabio


Tags: