Skip to content

PodiWan/desseract

Repository files navigation

desseract

Your friendly neighbourhood tessaract wrapper for dotnet.

Dependencies

This package is a Tesseract wrapper. Understandably, you are required to have it installed on your machine.

Using the API

The OCR exposes two Engine constructors, one accepting an input parameter and a parameterless one.

var engine = new Engine();
engine.InputSource = "example.png";

var response = await engine.ProcessAsync();
if (response.Status == EngineStatus.Success)
    Console.WriteLine(response.Output);
else
    Console.WriteLine("Could not parse file");

You could also do

var engine = new Engine("example.png");

var response = await engine.ProcessAsync();
if (response.Status == EngineStatus.Success)
    Console.WriteLine(response.Output);
else
    Console.WriteLine("Could not parse file");

Running these snippets on the example.png image give the following result:

Image

1234567890

Results

1234567890

About

An open-source cross-platform tessaract wrapper for dotnet.

Topics

Resources

Stars

Watchers

Forks

Contributors

Languages