Class OcrParameters
- Namespace
- LMKit.Extraction.Ocr
- Assembly
- LM-Kit.NET.dll
Encapsulates all parameters required to perform OCR on an image, including the raw image data, an optional Attachment for contextual metadata, and an optional LM model for extending OCR capabilities.
public sealed class OcrParameters
- Inheritance
-
OcrParameters
- Inherited Members
Remarks
If an LM Model is supplied, it can be leveraged by downstream OCR
components to provide enhanced functionality, such as automatic language detection, text
classification, or other language-aware post-processing tasks. When Model is
null
, OCR runs with its standard capabilities only.
Constructors
- OcrParameters(ImageBuffer, LM)
Initializes a new instance of the OcrParameters class with the specified image and an optional language model for extended OCR capabilities.
Properties
- Attachment
Gets the optional Attachment associated with the image data. This can be used to carry additional metadata (e.g., file name, source ID) alongside the image being processed.
- Image
Gets the ImageBuffer containing the raw pixel data to be used for OCR.
- ImageData
Gets the raw image data as a PNG-encoded byte array.
- Mime
Gets the MIME type of the image data.