Skip to content
DemoFAQ

PDF Generation Template Editor

Open-source visual PDF generation engine with customizable templates and developer-friendly APIs.

View on GitHub

Convert PDF to OFD ​

Overview ​

ComPDF Conversion SDK supports converting PDF documents to OFD documents. Similar to searchable PDF, OFD conversion also supports OCR, page background preservation, and transparent text layers.

Sample ​

go
inputFilePath := "***"
password := "***"
outputFileName := "***"

ofdOptions := compdf.NewOfdOptions()
ofdOptions.EnableOCR = true
ofdOptions.Languages = []compdf.OCRLanguage{compdf.OCRLangEnglish}
err := compdf.StartPDFToOfd(inputFilePath, password, outputFileName, ofdOptions, nil)