=====================================
===<Tim (Image to Text converter)>===
=====================================

The program converts an image (jpg or bmp) to a text, which looks like the image in grayscale. You can choose any monospaced font and any font size you want to format the text with, and also any set of allowed characters. The result can be saved as text and then you can format it correctly in a text editor, or you can save the image of the text already correctly formatted.

The program was written in C++Builder 2006 and might need some dll's and bpl's to run. They might be available for download here: http://etonne.110mb.com/files/libs.zip
Put them in the program directory, or in your system directory.

The program is rather intuitive. To convert an image to text:
- Adjust the character set that you want to use in conversion. You can do this by clicking them or by selecting or deselecting predefined ranges of characters.
- Change some font attributes by clicking the font button. (Note that the font you choose is the font that will REALLY be used, so if you choose font size 2 and then, after conversion, you view the text with font 3, it might not look good. If you want to change the "text resolution" of the resulting image, but do not want to change the font size, you should change magnitude of the image (described later).) After selecting new font, the program will recalculate the "light" of each character, it might take a while.
- Load the image by clicking Load picture or by drag-dropping the image on the form.
- Select the part of the image that you want to convert. Right-click on the image to place one corner of the selection, left-click to place the other. By default the whole image is selected.
- Adjust magnitude. Below the image you see: Pict: size of the picture, Sel: size of the selection, Mag: magnification (set this using the arrow buttons, arrow keys when the field has focus), Size: size of the magnified selection, Text: text resolution (number of columns and rows of characters in converted text).
- Click Draw Histogram. Histogram of the image will be calculated and displayed.
- Adjust color mapping by moving the line (right-click and left-click to move the two control points on it). In general, you should map the dark edge of the image histogram to the dark edge of the character set histogram and so on, but you might want to emphasize some parts of the image more than some others, and then letting parts of the image to be completely white or dark might be a good idea. You can also first draw a histogram for the part of the image that you want to map correctly, then adjust the mapping, and then select the whole image again and convert it using the previously prepared mapping. The more steep the line is, the better contrast you will have, but some parts of the image will map to the max dark or light characters. If you do not want completely white areas to appear on the image after conversion, simply exclude whitespace (and possibly also #160 and some more blank characters) from the character set.
- Now click Covert to see the result!
- If you are not satisfied with your text-image, you can adjust color weights by moving the three sliders. You will probably need to adjust the color mapping once more. Experiment with the sliders and color mapping until you get the desired effect.

Some of the steps above can be carried out in any order, you do not have to follow the instruction carefully. Or if you do not like such a lot of options, then just experiment for a moment with the program, and you will see that it is easier than it looks at first.

Have fun!

---

The program is Copyright 2007 by TPReal.

The software is donationware: you can freely use it, copy it, give it to your friends and store it on your file server as long as:
- no file in the distribution is modified or missing (including Tim.txt), and the program is not reverse-engineered in any way,
- you don't charge for it, even with virtual money, and don't use it to incite people to register in any commercial database or service.

Tim is distributed "as is", without any warranty, expressed or implied, or promise of technical support or future upgrade. Tim seems to work as expected, at least under the systems where it was tested, but the author disclaims any liability of any kind for any loss of data, damages, etc. or any consequential effect.

http://www.donationcoder.com/
http://www.donationcoder.com/Forums/bb/index.php?action=profile;u=37079
trnraos@o2.pl
