Can someone give me a pointer on how to solve this scenario:
1) I have an image of a chessboard (8x8) with black and white squares. I need to analyze the image and create a 8x8 matrix corresponding to the chessboard.
2) Store 0 if the corresponding chessboard cell is white, store 1 if the corresponding chessboard is black

The chessboard images have constant size, color depth and resolution. The image might be rotated.

What kind of image? PNG? Bitmap? Some other format?

Png or bitmap or jpeg. I know there is a brute force approach to check for rgb values of every pixel, but is there anything else?

edge detection? Or find first black pixels and see if it is corner, use it to choose between alternatives starting with 1 or starting with 0.

I think you do not give full info, for example there must be some background also.

edge detection? Or find first black pixels and see if it is corner, use it to choose between alternatives starting with 1 or starting with 0.

I think you do not give full info, for example there must be some background also.

I want to digitize hundreds of chess puzzles from Russian hobby journals. The puzzles are scanned into PDF. I extracted images and now want to convert chessboards into arrays

could you not post what you have and atttach few of the pictures from advanced editor -> manage attachments. Sounds interesting.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.