Croatian OCR in C# and .NET
이 문서의 다른 버전:
IronOCR 은 .NET 개발자가 크로아티아어를 포함한 126개 언어로 된 이미지와 PDF 문서에서 텍스트를 읽을 수 있도록 해주는 C# 소프트웨어 구성 요소입니다. 이는 .NET 개발자 전용으로 제작된 Tesseract의 고급 포크 버전으로, 속도와 정확도 면에서 다른 Tesseract 엔진보다 뛰어난 성능을 보여줍니다.
IronOCR 의 내용.언어.크로아티아어
이 패키지는 .NET 용 OCR 언어 49개를 지원합니다.
- 크로아티아어
- 크로아티아 최고
- CroatianFast
다운로드
크로아티아어 언어 팩 [hrvatski jezik]
설치
첫 번째 단계는 NuGet 사용하여 크로아티아어 OCR 패키지를 .NET 프로젝트에 설치하는 것입니다.
Install-Package IronOcr.Languages.Croatian
코드 예제
이 C# 코드 예제는 이미지 또는 PDF 문서에서 크로아티아어 텍스트를 읽습니다.
// Add the required namespace for IronOCR
using IronOcr;
class OCRExample
{
public static void Main()
{
// Create a new IronTesseract instance
var Ocr = new IronTesseract();
// Set the OCR language to Croatian
Ocr.Language = OcrLanguage.Croatian;
// Define the input image or PDF containing Croatian text
using (var Input = new OcrInput(@"images\Croatian.png"))
{
// Perform OCR on the input
var Result = Ocr.Read(Input);
// Extract all recognized text
var AllText = Result.Text;
// Output the recognized text to the console
System.Console.WriteLine(AllText);
}
}
}
// Add the required namespace for IronOCR
using IronOcr;
class OCRExample
{
public static void Main()
{
// Create a new IronTesseract instance
var Ocr = new IronTesseract();
// Set the OCR language to Croatian
Ocr.Language = OcrLanguage.Croatian;
// Define the input image or PDF containing Croatian text
using (var Input = new OcrInput(@"images\Croatian.png"))
{
// Perform OCR on the input
var Result = Ocr.Read(Input);
// Extract all recognized text
var AllText = Result.Text;
// Output the recognized text to the console
System.Console.WriteLine(AllText);
}
}
}
' Add the required namespace for IronOCR
Imports IronOcr
Friend Class OCRExample
Public Shared Sub Main()
' Create a new IronTesseract instance
Dim Ocr = New IronTesseract()
' Set the OCR language to Croatian
Ocr.Language = OcrLanguage.Croatian
' Define the input image or PDF containing Croatian text
Using Input = New OcrInput("images\Croatian.png")
' Perform OCR on the input
Dim Result = Ocr.Read(Input)
' Extract all recognized text
Dim AllText = Result.Text
' Output the recognized text to the console
System.Console.WriteLine(AllText)
End Using
End Sub
End Class
설명
- IronTesseract : OCR 작업을 수행하는 데 사용되는 주요 클래스입니다. 이미지나 PDF 파일에서 텍스트를 읽어오고 여러 언어를 지원합니다.
- OcrInput : OCR의 입력 소스를 나타냅니다. 입력 소스는 이미지 또는 PDF 파일일 수 있습니다.
- Ocr.Read : 지정된 입력에 대해 OCR 프로세스를 실행합니다.
- Result.Text : 입력에서 추출된 텍스트를 포함하며, 이 텍스트는 콘솔에 출력됩니다.

