Hi there,
We are using Aspose.CAD 23.0 for .NET and the following code to convert to PDF the input.dwg file to output.dwg.pdf. I attached all the resources here: DWG to PDF.zip (412.1 KB)
using (var image = Image.Load(input))
{
var cadPageSizes = CadPageSizesForA4(image.UnitType);
var rasterizationOptions = new CadRasterizationOptions
{
PageWidth = cadPageSizes.PageWidth,
PageHeight = cadPageSizes.PageHeight,
UnitType = cadPageSizes.UnitType,
DrawType = CadDrawTypeMode.UseObjectColor
};
image.Save(output, new PdfOptions
{
VectorRasterizationOptions = rasterizationOptions
});
}
Please check the PNGs with how the input is rendered in Autodesk’s Trueviewer and the output.dwg.pdf file that we get using the aforementioned code:
- Page 2 is not grayscale
- Pages 5-7 no longer have opacity
Can you please assist in debugging this? Maybe the DrawType is messing with this conversion?
Best regards.