OCR bretón en C# y .NET
IronOCR es un componente de software en C# que permite a los programadores de .NET leer texto de imágenes y documentos PDF en 126 idiomas, incluido el bretón. Es una bifurcación avanzada de Tesseract, creada exclusivamente para desarrolladores de .NET y supera regularmente a otros motores de Tesseract tanto en velocidad como en precisión.
Contenido de IronOcr.Languages.Breton
Este paquete contiene 43 idiomas OCR para .NET:
- Bretón
- BretónMejor
- BretónRápido
Descargar
Paquete de Idioma Bretón [brezhoneg]
Instalación
Lo primero que debemos hacer es instalar nuestro paquete OCR de Bretón en tu proyecto .NET.
Install-Package IronOCR.Languages.Breton
Ejemplo de código
Este ejemplo de código C# lee texto en bretón de una imagen o documento PDF.
// Import the IronOCR namespace
using IronOcr;
class Program
{
static void Main()
{
// Initialize the IronTesseract OCR engine
var Ocr = new IronTesseract();
// Set the OCR language to Breton
Ocr.Language = OcrLanguage.Breton;
// Read text from a Breton image or PDF document
using (var Input = new OcrInput(@"images\Breton.png"))
{
// Perform OCR on the input
var Result = Ocr.Read(Input);
// Extract text from the OCR result
var AllText = Result.Text;
// Output the extracted text
Console.WriteLine(AllText);
}
}
}// Import the IronOCR namespace
using IronOcr;
class Program
{
static void Main()
{
// Initialize the IronTesseract OCR engine
var Ocr = new IronTesseract();
// Set the OCR language to Breton
Ocr.Language = OcrLanguage.Breton;
// Read text from a Breton image or PDF document
using (var Input = new OcrInput(@"images\Breton.png"))
{
// Perform OCR on the input
var Result = Ocr.Read(Input);
// Extract text from the OCR result
var AllText = Result.Text;
// Output the extracted text
Console.WriteLine(AllText);
}
}
}' Import the IronOCR namespace
Imports IronOcr
Friend Class Program
Shared Sub Main()
' Initialize the IronTesseract OCR engine
Dim Ocr = New IronTesseract()
' Set the OCR language to Breton
Ocr.Language = OcrLanguage.Breton
' Read text from a Breton image or PDF document
Using Input = New OcrInput("images\Breton.png")
' Perform OCR on the input
Dim Result = Ocr.Read(Input)
' Extract text from the OCR result
Dim AllText = Result.Text
' Output the extracted text
Console.WriteLine(AllText)
End Using
End Sub
End Class- Este ejemplo demuestra cómo usar la biblioteca IronOCR para realizar OCR en una imagen de texto en bretón.
IronTesseractproporciona la funcionalidad central de OCR.- Se crea
OcrInputcon la ruta a la imagen que contiene texto en bretón. - El método
Readprocesa la imagen de entrada y extrae el texto, que luego se muestra en la consola.





