Confusing documentation

I am so confused by all the different namespaces for Aspose.PDF. The documentation is all over the place and finding out how to do a task is a monumental feat. I just want to know the most efficient way to convert a TIFF image to a PDF. I have to choose between DOM, Generator, Facades, and something called PDFMend. What???

Hi Joseph,

Thanks for your inquiry. Please note that Aspose.Pdf.Generator (Old generator) is only used to create PDF files from scratch and will soon be obsolete. Aspose.Pdf.Document (DOM) is the new generator and can create new PDF files from scratch and also manipulate existing PDF files. Aspose.Pdf.Facades (Facades) is used only to manipulate existing PDF files, such as PdfMend.

We suggest you use the DOM approach for converting TIFF images to PDF. Please find a sample code snippet for this purpose:

Document doc = new Document();
Page page = doc.Pages.Add();

// Create an image object in the section
Aspose.Pdf.Image image1 = new Aspose.Pdf.Image();

// Add image object into the Paragraphs collection of the section
page.Paragraphs.Add(image1);

// Set the path of image file
image1.File = myDir + "TEST.TIF";

// Specify the image Width and Height information equal to page Width and Height
image1.FixWidth = page.PageInfo.Width - page.PageInfo.Margin.Left - page.PageInfo.Margin.Right;
image1.FixHeight = page.PageInfo.Height - page.PageInfo.Margin.Top - page.PageInfo.Margin.Bottom;

doc.Save(myDir + "out.pdf");

Hi Joseph,


Adding more to Tilal’s comments, the PdfFileMend class is used to add Text, Image as watermark to PDF file. As suggested earlier, please try using the new Document Object Model (DOM) approach of Aspose.Pdf namespace.

Thanks. I’ll have to give that a try. Put in a quick fix using my ActivePDF Toolkit solution. Those resulting files are abuot 10% of the size of the Aspose produced PDFs, but retain high quality.

Hi Joseph,


Thanks for your feedback. You may consider following documentation link to reduce the file by compressing the images. You can also control the resolution and quality of the images. Hopefully it will help you to accomplish the task.


Please feel free to contact us for any further assistance.

Best Regards,