Cyrillic Alphabet OCR in C#

126 More Languages

IronOCR is a C# software component allowing .NET coders to read text from images and PDF documents in 126 languages, including the Cyrillic Alphabet.

It is an advanced fork of Tesseract, built exclusively for .NET developers and regularly outperforms other Tesseract engines in both speed and accuracy.

Contents of IronOcr.Languages.Cyrillic

This package contains 73 OCR languages for .NET:

  • CyrillicAlphabet
  • CyrillicAlphabetBest
  • CyrillicAlphabetFast

Download

Cyrillic Alphabet Language Pack [Cyrillic scripts]

Installation

The first thing you have to do is install the Cyrillic Alphabet OCR package to your .NET project.

Install-Package IronOCR.Languages.Cyrillic

Code Example

This C# code example reads Cyrillic Alphabet text from an Image or PDF document.

using IronOcr;

public class OcrExample
{
    public void ReadCyrillicText()
    {
        // Initialize a new instance of the IronTesseract OCR engine
        var Ocr = new IronTesseract();

        // Set the OCR engine to use the Cyrillic language package
        Ocr.Language = OcrLanguage.Cyrillic;

        // Create a new OCR input from an image file
        using (var Input = new OcrInput(@"images\Cyrillic.png"))
        {
            // Read the image using the OCR engine
            var Result = Ocr.Read(Input);

            // Retrieve Recognized Text
            var AllText = Result.Text;

            // Output the recognized text to the console
            Console.WriteLine(AllText);
        }
    }
}
using IronOcr;

public class OcrExample
{
    public void ReadCyrillicText()
    {
        // Initialize a new instance of the IronTesseract OCR engine
        var Ocr = new IronTesseract();

        // Set the OCR engine to use the Cyrillic language package
        Ocr.Language = OcrLanguage.Cyrillic;

        // Create a new OCR input from an image file
        using (var Input = new OcrInput(@"images\Cyrillic.png"))
        {
            // Read the image using the OCR engine
            var Result = Ocr.Read(Input);

            // Retrieve Recognized Text
            var AllText = Result.Text;

            // Output the recognized text to the console
            Console.WriteLine(AllText);
        }
    }
}
Imports IronOcr

Public Class OcrExample
	Public Sub ReadCyrillicText()
		' Initialize a new instance of the IronTesseract OCR engine
		Dim Ocr = New IronTesseract()

		' Set the OCR engine to use the Cyrillic language package
		Ocr.Language = OcrLanguage.Cyrillic

		' Create a new OCR input from an image file
		Using Input = New OcrInput("images\Cyrillic.png")
			' Read the image using the OCR engine
			Dim Result = Ocr.Read(Input)

			' Retrieve Recognized Text
			Dim AllText = Result.Text

			' Output the recognized text to the console
			Console.WriteLine(AllText)
		End Using
	End Sub
End Class
$vbLabelText   $csharpLabel
  • IronTesseract: This is the OCR engine class you use to configure and execute OCR tasks.
  • OcrInput: A class representing the input image or document you want to perform OCR on.
  • OcrLanguage.Cyrillic: Specifies that the OCR engine should use the Cyrillic language package for recognition.
  • Result.Text: Accesses the recognized text from the OCR result object.

This example demonstrates a simple use case where an image with Cyrillic text is processed to extract the text.