Browse our Products

Aspose.OCR for .NET 24.5.0 - Release Notes

Deprecation warning

What was changed

KeySummaryCategory
OCRNET‑842
OCRNET‑843
Automatic detection of problematic areas of an image that can significantly impact the accuracy of OCR.New feature
OCRNET‑845Significantly improved recognition of languages based on the Latin alphabet.Enhancement
OCRNET‑844Fixed character bounding boxes detection.Fix

Public API changes and backwards compatibility

This section lists all public API changes introduced in Aspose.OCR for .NET 24.5.0 that may affect the code of existing applications.

Added public APIs:

The following public APIs have been added to Aspose.OCR for .NET 24.5.0 release:

Aspose.OCR.AsposeOcr.DetectDefects() method

Automatically find potentially problematic areas of image and return the information on the type of defect and its coordinates.

Aspose.OCR.DefectType enumeration

Image defects that can be detected automatically:

DefectValueDescription
Salt-and-pepper noiseAspose.OCR.DefectType.SALT_PEPPER_NOISEAppears as random white and black pixels scattered across the area. Often occurs in digital photographs.
Low contrast between text and backgroundAspose.OCR.DefectType.LOW_CONTRASTHighlights and shadows typically appear on curved pages.
BlurAspose.OCR.DefectType.BLURThe entire image or some of its areas are out of focus.
Important: This detection algorithm can only identify the entire image as blurry. Specific areas cannot be detected.
GlareAspose.OCR.DefectType.GLAREHighlight areas in an image caused by uneven lighting, such as spot lights or flash.
All supported defectsAspose.OCR.DefectType.ALLAll above-mentioned defects.

Aspose.OCR.DefectAreas class

Image areas containing a certain type of defect.

PropertyTypeDescription
defectTypeAspose.OCR.DefectTypeDefect type.
rectanglesRectangle[]Image areas where the defect was found.

Aspose.OCR.DefectOutput class

Image areas containing a certain type of defect.

PropertyTypeDescription
SourcestringThe full path to the file or URL, if any. Empty for streams, byte arrays, and Base64 encoded files.
PageintThe page number for multi-page images and PDFs.
defectAreasList<DefectAreas>The list of image defects and areas where they were found.

Updated public APIs:

No changes.

Removed public APIs:

No changes.

Changes to application logic

We have significantly improved an OCR model for all languages based on Latin alphabet:

  • English
  • Indonesian
  • Italian
  • Malay (Melayu)
  • Hausa
  • Swahili
  • Yoruba
  • Oromo
  • Dutch
  • Malagasy
  • Zhuang
  • Somali
  • Chichewa (Chewa, Nyanja)
  • Rwanda
  • Min Bei
  • Zulu
  • Min Dong
  • Hiligaynon
  • Hmong
  • Shona (Karanga)
  • Xhosa
  • Betawi
  • Afrikaans
  • Minangkabau
  • Sotho (Southern)
  • Bikol
  • Kanuri
  • Tswana
  • Luo
  • Sukuma
  • Tsonga
  • Bemba (Chibemba)
  • Nandi
  • Palembang
  • Umbundu
  • Sotho (Northern)
  • Waray-Waray
  • Lamani (Lambadi)
  • Musi
  • Pu-Xian
  • Kapampangan
  • Bouyei (Buyi, Giáy)
  • Ndebele
  • Sasak
  • Swati (Swazi)
  • Gusii
  • Meru
  • Wolaytta
  • Dong
  • Pangasinan
  • Makassar (Makasar)
  • Tumbuka
  • Serer-Sine
  • LaTonga
  • Luguru
  • Latin

Examples

The code samples below illustrate the changes introduced in this release:

Detect shadows and highlights

var api = new Aspose.OCR.AsposeOcr();
var input = new OcrInput(InputType.SingleImage);
input.Add("source.png");
// Find shadows and highlights
var defects = api.DetectDefects(input, DefectType.LOW_CONTRAST);
foreach (var defect in defects)
{
	Console.WriteLine($"Image path: {defect.Source} | Page: {defect.Page}");
	foreach (var areas in defect.defectAreas)
	{
		Console.WriteLine($"Number of low-contrast areas: {areas.rectangles.Count()}");
	}
}