This short tutorial focuses on how to convert IGES to PDF in Java by providing all the necessary details and steps to use the example code. In this example, we have provided a sample code to export the IGES file to PDF in Java using simple API calls and the application can be used in any Java environment configured in Windows, macOS or Linux.
Steps to Convert a File From IGES to PDF in Java
- Configure your project to add the Aspose.CAD for Java Jar file from the repository manager
- Access the source IGES file using the Image class object
- Initialize the CadRasterizationOptions class object to customize the rasterization of the IGES file
- Initialize and use the PdfOptions class object to configure the output PDF options
- Convert the IGES file to PDF using the save method exposed by the Image class
The aforementioned steps cover the process to convert IGES file to PDF in Java, whereby the process is commenced by loading the source IGES file using the Image class object from the disk. Then PdfOptions object is used to set the output PDF properties and apply the IGES rasterization options, which is then followed by saving the IGES as PDF on the disk by providing PdfOptions object as an argument.
Code to Convert IGES to PDF in Java
This code example can be used to develop an IGES to PDF converter software in Java by using a simple API interface. The CadRasterizationOptions class is employed to customize the rasterization process by setting the page size, background color, layouts in rendered PDF, draw type, pen options, draw color and quality.
We have witnessed exporting from IGES to PDF in Java in this topic using the simple API interface. If you are keen to learn about the process of converting DGN to PDF refer to the article on how to Convert DGN to PDF in Java.