Get Background and Text color for each letter using FineReader Engine


Is it possible to get background and text color for each letter individually using the GetTextBackgroundColor method of FREngine? 



GetTextBackgroundColor used in combination with BitMap and OnCrop methods will allow us to recognize color from a defined part of the image receiving precise results depending on picture quality. 

But is not suitable in case we want to get text and background color from the text presented in the sample image.

Logo, company name

Description automatically generated

There are a few ways of extracting colors separately from every letter.

  • First, we may use OnCrop as well, separating every letter from the original image. 
    It is possible to do that but in some working scenarios, it may be inefficient. 
  • As a second option, we may try using the specifics of our software to our advantage. 
    The text extraction from a document consists of several stages. 
    Before text will be extracted and exported as a separate document it will be recognized and the text region will be chosen.
    The trick is, at this stage, before the text will be extracted we can use a marked region in combination with GetTextBackgroundColor to get separate colors for each letter.

More information regarding the second method can be found here.













Have more questions? Submit a request



Please sign in to leave a comment.