  Matlab version 7.1 had been used to detect playing cards on a Casino table
and the suits and ranks of these cards had been identified. The process gives
an example of an application of computer vision to a problem where rectangular
objects are to be detected and the information content of the objects are
extracted out. In the case of playing cards, it is the suit and rank of each
card. The image processing system is done in two passes. Pass 1 detects
rectangular shapes and template matched with a template of the left and right
edges of the cards. Pass 2 extracts the suit and rank of the cards by matching
the top left portion of the card that contains both rank and suit information,
with stored templates of ranks and suits of the playing cards using a series of
if-then statements.
