How to remove shadow from image ?
47 views (last 30 days)
Show older comments
Zaheer Abbas
on 26 Mar 2017
Commented: Zaheer Abbas
on 27 Mar 2017
I am building a braille dots recognition program. After i acquire image through the camera and convert it into binary, the shadow also becomes significant and hence the result gets affected. Can you suggest me a code to avoid the effect of shadows?? Here is the example image(shadow is on the bottom half part of the image):
Here is the Binary image:
Histogram of the Orignal Image:
Accepted Answer
Image Analyst
on 27 Mar 2017
Try this example: https://www.mathworks.com/help/images/examples/correcting-nonuniform-illumination.html?prodcode=IP&language=en
Other methods that would also work are adapthisteq() and imtophat() or imbothat().
You can also use John D'Errico's polyfitn() to fit the background to a 2-D polymonial. See my attached demo.
More Answers (0)
See Also
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!