I have a JPEG file with a 200 dpi scan of a sample printout from a badly maintained old drum printer. I was able to segment it and to collect all instances of each letter together, for example
I would like to recreate its font; as the first step I've written a utility that estimates the shift amount (in pixels) between two images using MSE, then weighted-averages them according to that shift amount, and continues until all instances of a character have been processed.
My results look like
Is this the best I can hope for, or are there smarter algorithms that are able to deal with low-quality samples?
Specifically, I would like to get rid of the ink smear at the top of the characters due to the rotational momentum of the drum with respect to the hammers.
(As far as I understand, super-resolution is not a good match for this task, and I couldn't find a good open source implementation of it.)
The second step is to use Potrace, of course.
Initial image Charset encoding Segmented
– Leo B. May 27 '17 at 16:44