Occitan OCR in C# and .NET
IronOCR ist eine C# Softwarekomponente, die .NET-Programmierern ermöglicht, Text aus Bildern und PDF-Dokumenten in 126 Sprachen, einschließlich Okzitanisch, zu lesen. Es ist eine erweiterte Abspaltung von Tesseract, die exklusiv for .NET-Entwickler entwickelt wurde und regelmäßig andere Tesseract-Engines sowohl in Bezug auf Geschwindigkeit als auch Genauigkeit übertrifft.
Inhalte von IronOcr.Languages.Occitan
Dieses Paket enthält 46 OCR-Sprachen for .NET:
- Okzitanisch
- OkzitanischBest
- OkzitanischFast
Download
Okzitanisches Sprachpaket
Installation
Das Erste, was wir tun müssen, ist unser Okzitanisch OCR-Paket in Ihrem .NET-Projekt zu installieren.
Install-Package IronOcr.Languages.Occitan
Beispielcode
Dieses C# Codebeispiel liest okzitanischen Text aus einem Bild oder PDF-Dokument.
// Importing the IronOCR namespace
using IronOcr;
class Program
{
static void Main()
{
// Create a new instance of the OCR engine for Occitan language
var Ocr = new IronTesseract();
Ocr.Language = OcrLanguage.Occitan;
// Use a using block for proper disposal of resources
using (var Input = new OcrInput(@"images\Occitan.png"))
{
// Perform OCR on the input image
var Result = Ocr.Read(Input);
// Retrieve the recognized text
var AllText = Result.Text;
// Output the recognized text to the console
Console.WriteLine(AllText);
}
}
}
// Importing the IronOCR namespace
using IronOcr;
class Program
{
static void Main()
{
// Create a new instance of the OCR engine for Occitan language
var Ocr = new IronTesseract();
Ocr.Language = OcrLanguage.Occitan;
// Use a using block for proper disposal of resources
using (var Input = new OcrInput(@"images\Occitan.png"))
{
// Perform OCR on the input image
var Result = Ocr.Read(Input);
// Retrieve the recognized text
var AllText = Result.Text;
// Output the recognized text to the console
Console.WriteLine(AllText);
}
}
}
' Importing the IronOCR namespace
Imports IronOcr
Friend Class Program
Shared Sub Main()
' Create a new instance of the OCR engine for Occitan language
Dim Ocr = New IronTesseract()
Ocr.Language = OcrLanguage.Occitan
' Use a using block for proper disposal of resources
Using Input = New OcrInput("images\Occitan.png")
' Perform OCR on the input image
Dim Result = Ocr.Read(Input)
' Retrieve the recognized text
Dim AllText = Result.Text
' Output the recognized text to the console
Console.WriteLine(AllText)
End Using
End Sub
End Class
Dieses Beispiel zeigt, wie man die IronOCR-Bibliothek konfiguriert, um Text aus einer Bilddatei mit okzitanischem Text zu lesen. Es setzt die OCR-Sprache auf Okzitanisch und verarbeitet das Bild, wobei der erkannte Text ausgegeben wird.

