alexa
menu

Document Processing

    Show / Hide Table of Contents

    OcrImageEnhancementMode Class

    Specifies how image enhancement is applied during OCR processing.

    Inheritance
    System.Object
    OcrImageEnhancementMode
    Namespace: Syncfusion.OCRProcessor
    Assembly: Syncfusion.OCRProcessor.Base.dll
    Syntax
    public sealed class OcrImageEnhancementMode : Enum
    Examples
    // Initialize the OCR processor.
    OCRProcessor processor = new OCRProcessor();
    //loading the input image.
    FileStream stream = new FileStream(@"Input.pdf", FileMode.Open);
    PdfLoadedDocument document = new PdfLoadedDocument(stream);
    sets the image enhancement mode used for OCR processor
    processor.ImageEnhancementMode = OcrImageEnhancementMode.EnhanceForRecognitionOnly;
    document = processor.PerformOCR(document);
    FileStream outputStream = new FileStream("Output.pdf", FileMode.CreateNew);
    //Save the document into stream.
    document.Save(outputStream);
    document.Close(true);

    Fields

    EnhanceAndIncludeInOutput

    Image is enhanced and the enhanced version is used in the output document.

    Declaration
    public const OcrImageEnhancementMode EnhanceAndIncludeInOutput
    Field Value
    Type
    OcrImageEnhancementMode

    EnhanceForRecognitionOnly

    Image is enhanced internally to improve OCR accuracy, but the original image is retained in the output.

    Declaration
    public const OcrImageEnhancementMode EnhanceForRecognitionOnly
    Field Value
    Type
    OcrImageEnhancementMode

    None

    No image enhancement is performed. The original image is used for OCR processing.

    Declaration
    public const OcrImageEnhancementMode None
    Field Value
    Type
    OcrImageEnhancementMode
    Back to top Generated by DocFX
    Copyright © 2001 - 2026 Syncfusion Inc. All Rights Reserved