OCR turco en C# y .NET

This article was translated from English: Does it need improvement?
Translated
View the article in English
Other versions of this document:

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 turco.

Es una versión avanzada de Tesseract, construida exclusivamente para desarrolladores de .NET y que supera regularmente a otros motores Tesseract tanto en velocidad como en precisión.

Contenido de IronOcr.Languages.Turkish

Este paquete contiene 46 idiomas OCR para .NET:

  • Turco
  • TurcoMejor
  • TurcoRápido

Descargar

Paquete de idioma turco [Türkçe]

Instalación

El primer paso es instalar el paquete OCR Turco en tu proyecto .NET usando el siguiente comando del administrador de paquetes NuGet.

Install-Package IronOCR.Languages.Turkish

Ejemplo de código

Este ejemplo de código en C# demuestra cómo leer texto turco de una imagen o documento PDF.

// Import the IronOcr namespace
using IronOcr;

class OCRExample
{
    static void Main()
    {
        // Create a new IronTesseract object
        var Ocr = new IronTesseract();

        // Set the OCR language to Turkish
        Ocr.Language = OcrLanguage.Turkish;

        // Define the input using a path to the image or PDF file
        using (var Input = new OcrInput(@"images\Turkish.png"))
        {
            // Perform the OCR reading operation
            var Result = Ocr.Read(Input);

            // Retrieve the text from the OCR result
            var AllText = Result.Text;

            // Print the extracted text to the console
            Console.WriteLine(AllText);
        }
    }
}
// Import the IronOcr namespace
using IronOcr;

class OCRExample
{
    static void Main()
    {
        // Create a new IronTesseract object
        var Ocr = new IronTesseract();

        // Set the OCR language to Turkish
        Ocr.Language = OcrLanguage.Turkish;

        // Define the input using a path to the image or PDF file
        using (var Input = new OcrInput(@"images\Turkish.png"))
        {
            // Perform the OCR reading operation
            var Result = Ocr.Read(Input);

            // Retrieve the text from the OCR result
            var AllText = Result.Text;

            // Print the extracted text to the console
            Console.WriteLine(AllText);
        }
    }
}
' Import the IronOcr namespace
Imports IronOcr

Friend Class OCRExample
	Shared Sub Main()
		' Create a new IronTesseract object
		Dim Ocr = New IronTesseract()

		' Set the OCR language to Turkish
		Ocr.Language = OcrLanguage.Turkish

		' Define the input using a path to the image or PDF file
		Using Input = New OcrInput("images\Turkish.png")
			' Perform the OCR reading operation
			Dim Result = Ocr.Read(Input)

			' Retrieve the text from the OCR result
			Dim AllText = Result.Text

			' Print the extracted text to the console
			Console.WriteLine(AllText)
		End Using
	End Sub
End Class
$vbLabelText   $csharpLabel

Este código configura un proceso OCR utilizando IronOCR para leer texto turco de una imagen de entrada. Luego imprime el texto extraído en la consola.