Articles → CSHARP → OCR API In C#
OCR API In C#
Tesseract.NET.SDK Nugget Package
Sample Image
Code To Read Text From Image
using Patagames.Ocr;
using Patagames.Ocr.Enums;
using System;
namespace OCRInCSharp
{
class Program
{
static void Main(string[] args)
{
ConvertImageToText();
Console.ReadLine();
}
public static void ConvertImageToText()
{
using (var api = OcrApi.Create())
{
api.Init(Languages.English);
string plainText = api.GetTextFromImage("C:\\temp\\1.png");
Console.WriteLine(plainText);
}
}
}
}
Output