Occitan OCR in C# and .NET
O IronOCR é um componente de software C# que permite aos programadores .NET ler texto de imagens e documentos PDF em 126 idiomas, incluindo o occitano. Trata-se de uma versão avançada do Tesseract, criada exclusivamente para desenvolvedores .NET e que supera regularmente outros mecanismos do Tesseract em termos de velocidade e precisão.
Conteúdo de IronOcr.Languages.Occitan
Este pacote contém 46 linguagens de OCR for .NET:
- Occitano
- OccitanoBest
- OccitanoFast
Baixar
Pacote de Língua Occitana
Instalação
A primeira coisa que precisamos fazer é instalar nosso pacote OCR Occitan em seu projeto .NET.
Install-Package IronOcr.Languages.Occitan
Exemplo de código
Este exemplo de código C# lê texto em occitano de uma imagem ou documento PDF.
// 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
Este exemplo demonstra como configurar a biblioteca IronOCR para ler texto de um arquivo de imagem contendo texto em occitano. O programa define o idioma OCR para occitano e processa a imagem, gerando como saída o texto reconhecido.

