OCR slovène en C# et .NET

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

IronOCR est un composant logiciel C# qui permet aux développeurs .NET de lire du texte à partir d'images et de documents PDF dans 126 langues, dont le slovène. Il s'agit d'une version avancée de Tesseract, conçue exclusivement pour les développeurs .NET et qui surpasse régulièrement les autres moteurs Tesseract en termes de vitesse et de précision.

Contenu de IronOcr.Languages.Slovène

Ce package contient 46 langues OCR pour .NET :

  • Slovène
  • SlovèneBest
  • SlovèneFast

Télécharger

Pack de langue slovène [langue slovène]

  • Télécharger au format ZIP
  • Installer avec NuGet

Installation

La première chose à faire est d'installer le package OCR slovène dans votre projet .NET.

Install-Package IronOCR.Languages.Slovene

Exemple de code

Cet exemple de code C# montre comment lire du texte slovène à partir d'une image ou d'un document PDF.

// Install the package before using it.
// PM> Install-Package IronOcr.Languages.Slovene

using IronOcr;

class Program
{
    static void Main()
    {
        // Create a new instance of IronTesseract for OCR operations.
        var Ocr = new IronTesseract();

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

        // Perform OCR inside a using block to ensure resources are released properly.
        using (var Input = new OcrInput(@"images\Slovene.png"))
        {
            // Read the text from the input image or PDF.
            var Result = Ocr.Read(Input);

            // Get all the recognized text as a string.
            var AllText = Result.Text;

            // Output the recognized text to the console.
            System.Console.WriteLine(AllText);
        }
    }
}
// Install the package before using it.
// PM> Install-Package IronOcr.Languages.Slovene

using IronOcr;

class Program
{
    static void Main()
    {
        // Create a new instance of IronTesseract for OCR operations.
        var Ocr = new IronTesseract();

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

        // Perform OCR inside a using block to ensure resources are released properly.
        using (var Input = new OcrInput(@"images\Slovene.png"))
        {
            // Read the text from the input image or PDF.
            var Result = Ocr.Read(Input);

            // Get all the recognized text as a string.
            var AllText = Result.Text;

            // Output the recognized text to the console.
            System.Console.WriteLine(AllText);
        }
    }
}
' Install the package before using it.
' PM> Install-Package IronOcr.Languages.Slovene

Imports IronOcr

Friend Class Program
	Shared Sub Main()
		' Create a new instance of IronTesseract for OCR operations.
		Dim Ocr = New IronTesseract()

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

		' Perform OCR inside a using block to ensure resources are released properly.
		Using Input = New OcrInput("images\Slovene.png")
			' Read the text from the input image or PDF.
			Dim Result = Ocr.Read(Input)

			' Get all the recognized text as a string.
			Dim AllText = Result.Text

			' Output the recognized text to the console.
			System.Console.WriteLine(AllText)
		End Using
	End Sub
End Class
$vbLabelText   $csharpLabel