Hi,
I’m using Aspose.CAD.dll, version 19.5, for transform dwg file in pdf file.
I have two problems:
-
the result file doesn’t preserve original fonts.
-
the result file is too big (original file is about 2mb, result is about 9mb): I also tried to decrease dpi but the result is the same
here I attach the code:
using (Aspose.CAD.Image image = Aspose.CAD.Image.Load(strSourceFile))
{
Aspose.CAD.ImageOptions.CadRasterizationOptions rasterizationOptions = new Aspose.CAD.ImageOptions.CadRasterizationOptions();
rasterizationOptions.PageHeight = 100;
rasterizationOptions.AutomaticLayoutsScaling = false;
rasterizationOptions.NoScaling = true;
// Create an instance of PdfOptions
Aspose.CAD.ImageOptions.PdfOptions pdfOptions = new Aspose.CAD.ImageOptions.PdfOptions();
// Set the VectorRasterizationOptions property
pdfOptions.VectorRasterizationOptions = rasterizationOptions;
//Export CAD to PDF
image.Save(sDestFile, pdfOptions);
}