Converti PDF scansionato in PDF modificabile usando Java

This short tutorial explains how to convert the scanned PDF into an editable PDF using Java. Include details for setting up the IDE, a list of steps, and sample code to convert scanned PDFs into searchable PDFs using Java. You will get details to customize the image scanning process and the conversion of the content into readable text.

Passaggi per rendere leggibile un PDF con Java

  1. Set the IDE to use Aspose.Total for Java to convert a scanned PDF into a searchable PDF.
  2. Instantiate the corresponding product licenses to avoid watermarks in the output.
  3. Create an instance of the recognition engine using the AsposeOCR class.
  4. Create the input instance using the OcrInput class and load the original scanned PDF into it.
  5. Create the RecognitionSettings instance to set the parameters for customization during image scanning.
  6. Call the AsposeOCR method.Recognize() to retrieve the data from the scanned PDF and store it in a temporary PDF.
  7. Load the intermediate PDF into the Aspose Document class object.PDF and set the metadata inside it.
  8. Save the final PDF to disk with searchable text and metadata.

Questi passaggi descrivono come convertire un’immagine PDF in testo PDF usando Java. Creare l’oggetto del motore di riconoscimento, preparare il file di input aggiungendo il file PDF scansionato all’oggetto OcrInput, definire i parametri nell’oggetto RecognitionSettings, chiamare il metodo Recognize() per scansionare i dati e salvare i risultati in un file PDF intermedio. Finally, load the intermediate PDF file using the Aspose object.PDF.Document and add metadata or further format it before saving the final PDF file.

Codice per convertire immagini PDF in testo usando Java

Questo codice dimostra come convertire PDF in PDF ricercabile usando Java. It is possible to set a specific detection language during PDF scanning, set a flag for automatic language detection, limit recognition to specific characters, or exclude characters that you want the OCR to ignore. Options are also available to choose the detection strategy for the source document’s area/layout, if necessary.

This article taught us the process to convert a PDF into a selectable text PDF. To export data from a PDF form to Excel, refer to the article Export Data from a PDF Form to Excel using Java.

 Italiano