C# 和 .NET 中的阿尔巴尼亚语 OCR
Curtis Chau
更新:
本文档的其他版本:
IronOCR 是一个 C# 软件组件,.NET 开发人员可用它从图像和 PDF 文档中读取 126 种语言(包括阿尔巴尼亚语)的文本。IronOCR 是 Tesseract 的高级分支,专为 .NET 开发人员打造,识别速度和准确率通常优于其他 Tesseract 引擎。
IronOcr.Languages.Albanian 的内容
此软件包包含 49 种适用于 .NET 的 OCR 语言:
- Albanian
- AlbanianBest
- AlbanianFast
下载
阿尔巴尼亚语语言包 [gjuha shqipe]
安装
首先,在 .NET 项目中安装 阿尔巴尼亚语 OCR 软件包。
代码示例
这段 C# 代码示例从图像或 PDF 文档中读取阿尔巴尼亚语文本。
// This example demonstrates how to use IronOCR to extract text from an image using the Albanian language pack.
using IronOcr;
var Ocr = new IronTesseract(); // Create a new instance of the IronTesseract engine.
Ocr.Language = OcrLanguage.Albanian; // Set the OCR language to Albanian.
using (var Input = new OcrInput(@"images\Albanian.png")) // Provide path to the image file.
{
var Result = Ocr.Read(Input); // Perform OCR on the input image.
var AllText = Result.Text; // Extract the recognized text from the OCR result.
// Optionally, use the extracted text for further processing.
}' This example demonstrates how to use IronOCR to extract text from an image using the Albanian language pack.
Imports IronOcr
Private Ocr = New IronTesseract() ' Create a new instance of the IronTesseract engine.
Ocr.Language = OcrLanguage.Albanian ' Set the OCR language to Albanian.
Using Input = New OcrInput("images\Albanian.png") ' Provide path to the image file.
Dim Result = Ocr.Read(Input) ' Perform OCR on the input image.
Dim AllText = Result.Text ' Extract the recognized text from the OCR result.
' Optionally, use the extracted text for further processing.
End Using' This example demonstrates how to use IronOCR to extract text from an image using the Albanian language pack.
Imports IronOcr
Private Ocr = New IronTesseract() ' Create a new instance of the IronTesseract engine.
Ocr.Language = OcrLanguage.Albanian ' Set the OCR language to Albanian.
Using Input = New OcrInput("images\Albanian.png") ' Provide path to the image file.
Dim Result = Ocr.Read(Input) ' Perform OCR on the input image.
Dim AllText = Result.Text ' Extract the recognized text from the OCR result.
' Optionally, use the extracted text for further processing.
End UsingCurtis Chau 拥有卡尔顿大学的计算机科学学士学位,专注于前端开发,精通 Node.js、TypeScript、JavaScript 和 React。他热衷于打造直观且美观的用户界面,喜欢使用现代框架并创建结构良好、视觉吸引力强的手册。