Add additional image processing #1

Merged
pradana.aumars merged 2 commits from Yun/videocr:master into master 2021-07-13 16:16:53 +02:00

2 Commits

Author SHA1 Message Date
Yun aec2b9c95a fixup 2021-07-13 10:20:47 +02:00
Yun 7f6881749f Add additional image processing
Ordered process:
1. dilation - thicken white portion of subtitles
2. resize - temporary hardcoded to 47% (assuming subtitles are 68 pixels in height)
3. apply hsv color mask - filter out non gray pixels and filter out pixels that are not bright enough
4. invert image - make it black text on white background
5. add border to top and bottom - assuming subtitles are cropped closely
2021-07-13 09:12:43 +02:00