Sorry, i'm a bit late to reply; got busy.
You are really limited by the size of the image and thus the resolution available in pixels. You would do better if the image size were much larger.
I was finally able to get higher quality image here:
http://i.minus.com/ibiHhso9LbxL1f.png
try one of these ...
They give about the same quality I originally got. I think this is an OCR issue rather than preprocessing?Perhaps it needs to be trained better.
Also I would try to 'square up' the image more before trying to clean up the image. Phaps looking for the edge of the docket and the workbench to find the rotation.
Yeah, I should probably add that but currently, want to focus on straight images.
Finally. Just how much control do you have on the photographing?
Not much. I suppose most of the images are of the same quality as above. I have access only to the raw image files; cant do much about work area, flash,camera mounting,etc
EG: made dark, or some specific color (green felt) for easier auto docket rotation, and or removal.
Any built in function in imagemagick to do this?
The more you can control the environment, the easier it is to automate the OCR conversion, even without going to the expense of a dedicated high-res scanner.
I agree 1000%; scanned images would be much easier. Unfortunately, only the above type of camera images are available.
The simple use of an edge, for example means it is fast to position the docket and take the photo, allowing fast turn over of dockets thru the system. Perhaps even a real-time indication of a successful OCR conversion on the computer as you process each docket
I heard this kind of system was developed by a Google Book's developer using a hacked scanner.