Filipino OCR in C# and .NET
IronOCR is a C# software component allowing .NET coders to read text from images and PDF documents in 126 languages, including Filipino. 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.Filipino
This package contains 49 OCR languages for .NET:
- Filipino
- FilipinoBest
- FilipinoFast
Download
Filipino Language Pack [National Language of the Philippines]
Installation
The first thing we have to do is install our Filipino OCR package to your .NET project.
Install-Package IronOCR.Languages.Filipino
Code Example
This C# code example reads Filipino text from an image or PDF document.
// Import the IronOcr namespace to use its classes and methods.
using IronOcr;
class Program
{
static void Main()
{
// Create a new instance of the IronTesseract OCR engine.
var Ocr = new IronTesseract();
// Set the OCR language to Filipino.
Ocr.Language = OcrLanguage.Filipino;
// Create a new OcrInput object, specifying the path to the image
// or document that contains the text you want to read.
using (var Input = new OcrInput(@"images\Filipino.png"))
{
// Perform OCR on the input.
var Result = Ocr.Read(Input);
// Extract the read text from the OCR result.
var AllText = Result.Text;
// Output the text to the console or use it in your application.
Console.WriteLine(AllText);
}
}
}
// Import the IronOcr namespace to use its classes and methods.
using IronOcr;
class Program
{
static void Main()
{
// Create a new instance of the IronTesseract OCR engine.
var Ocr = new IronTesseract();
// Set the OCR language to Filipino.
Ocr.Language = OcrLanguage.Filipino;
// Create a new OcrInput object, specifying the path to the image
// or document that contains the text you want to read.
using (var Input = new OcrInput(@"images\Filipino.png"))
{
// Perform OCR on the input.
var Result = Ocr.Read(Input);
// Extract the read text from the OCR result.
var AllText = Result.Text;
// Output the text to the console or use it in your application.
Console.WriteLine(AllText);
}
}
}
' Import the IronOcr namespace to use its classes and methods.
Imports IronOcr
Friend Class Program
Shared Sub Main()
' Create a new instance of the IronTesseract OCR engine.
Dim Ocr = New IronTesseract()
' Set the OCR language to Filipino.
Ocr.Language = OcrLanguage.Filipino
' Create a new OcrInput object, specifying the path to the image
' or document that contains the text you want to read.
Using Input = New OcrInput("images\Filipino.png")
' Perform OCR on the input.
Dim Result = Ocr.Read(Input)
' Extract the read text from the OCR result.
Dim AllText = Result.Text
' Output the text to the console or use it in your application.
Console.WriteLine(AllText)
End Using
End Sub
End Class