-
Notifications
You must be signed in to change notification settings - Fork 1
Home
Identifying the different pieces through image recognition would be awfully complex, and most likely impossible with "exotic" chess sets (Harry Potter, StarWars, you name it...).
But, knowing the starting position of the game, we don't need to identify the pieces, as long as we can track them throughout the game. For that, assuming we can get one static image of the whole board after each move, all we need is:
- to be able to identify the 64 squares of the chessboard;
- for each square, to tell if it is occupied by a piece or if it is empty;
- if the square is occupied, to tell the color of the piece on it.
The third point is necessary in the case of forks: after the capture, if we can't tell if a piece is black or white, we can't tell which piece was actually captured.
Castling and en passant also work with this principle, the usual pitfall being of course the promotion. As a first implementation, we'll make the assumption that a pawn always promotes to Queen.
TODO