ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
Forum membership is Free!  Click Join to sign-up
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 Extracting handwritten text from a color image
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

Eric24

USA
23 Posts

Posted - Aug 24 2011 :  19:32:35  Show Profile  Reply
I'm hoping someone here with some experience doing this can point me in the right direction. What I have is a color scan of a handwritten document. The background is mostly "solid", but not "white" or any other single color, but rather shades of white/gray (think old paper). The handwriting is mostly written with blue or black ink, occasionally some other color. My objective is to extract the handwriting from the background.

So far, I'm thinking that some combination of "background color removal" and/or edge detection might do the trick. Is there some other approach I should consider? Any advice would be greatly appreciated!

Thank you!

fab

1310 Posts

Posted - Aug 25 2011 :  00:06:32  Show Profile  Reply
Please post a sample image.
Go to Top of Page

Eric24

USA
23 Posts

Posted - Aug 28 2011 :  20:05:26  Show Profile  Reply
Here's a simple one


69.01 KB.
Go to Top of Page

fab

1310 Posts

Posted - Aug 28 2011 :  22:24:07  Show Profile  Reply
You could try to apply a local threshold. For example:
ImageEnView1.Proc.ConvertToBWLocalThreshold(8, ietMeanMinMax, 6);

You may need to change parameters depending by the background.

Also, it may be necessary to remove isolated pixels with:
ImageEnView1.Proc.RemoveIsolatedPixels(0);


This is the result applying ConvertToBWLocalThreshold and RemoveIsolatedPixels to your image:
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: