Image to text

Hello. I am going to ask you a small question.
Can anybody help me making a small program to convert an image, .jpg ot .bmp to a .txt file?

the conversion would work like this:
if the pixel is dark the write a letter in the text file
else write space in the text file.

my only problem is that i dont know how to convert a pixels color to a number, and how to actually read the image.

If you have any suggestions, please leave a comment.
Thank you.
You could have a look at this first: http://csl.sublevel3.org/jp2a/
It sound like you're asking about character recognition in a JPG image. If not, please explain your question better. If so, you should learn how to open an image and understand that a pixel's color is already a number (3 numbers actually; the amount of red, blue and green) before you try to tackle this...
okey, you want me to explain better. I want to actually be able to see in a text file the amount of RGB colors each pixel has
Topic archived. No new replies allowed.