Ask Your Question

how to recognize poker chips stack from a side view

asked 2014-01-09 23:56:32 -0500

updated 2014-01-15 20:55:35 -0500

image descriptionHi!

I need the wisdom of my fellow opencv gurus for a fun but tricky problem. I am going to have a poker tournament with my friends at my home, and I wanted to record the money bet with a camera which will be placed on the side of the table.

The chips will be stacked in a single stack, and can have colors white, black, red, blue, green. I wanted to count the total value of chips bet by any player in the game. the players could be sitting close or away from the camera. For illustration, I have attached a pic to this post.

any help would be appreciated.

Here is the link to images from the table

edit retag flag offensive close merge delete


Pic doesnt work. You could try to segment the chips and then do a color detection of them

JAyThaRevo gravatar imageJAyThaRevo ( 2014-01-11 04:04:22 -0500 )edit

Thanks JayThaRevo, here is a link for the images: the main issue is that background subtraction doesnt reduce too much noise and without that, it is tough to isolate the chip stack and count the height. any ideas?

anksphenomenon gravatar imageanksphenomenon ( 2014-01-15 20:54:28 -0500 )edit

This is not a trivial task at all. One possible way to eliminate some complexity is to define where your friends have to place their chips so they are easier to segment, and then some HSV color detection. If you need to detect chip stacks on top of the table you are in for a treat :p

Good luck!

Pedro Batista gravatar imagePedro Batista ( 2014-01-16 10:13:22 -0500 )edit

1 answer

Sort by ยป oldest newest most voted

answered 2014-01-13 02:32:17 -0500

I was thinking for rectangle fitting and color detection... maybe ....

edit flag offensive delete link more


thanks Spas, i thought of that too. if you look at the images given in the question, it is tough to isolate the chip stack from the table as they are very similar in color. so color filtering gives a lot of noise. also the gradient in color change due to shadow emanating from the light source makes it harder to isolate the chip stack.

anksphenomenon gravatar imageanksphenomenon ( 2014-01-15 20:57:57 -0500 )edit

With that quality of the input video source will be nearly imposable to detect anything ... First try to use better cam (or just take some test shots with high quality DSLR or something from that class).

On high quality will be easier to develop the algorithm of the program, and after that will think for concrete implementation. ;)

Spas Hristov gravatar imageSpas Hristov ( 2014-01-16 10:58:18 -0500 )edit
Login/Signup to Answer

Question Tools


Asked: 2014-01-09 23:56:32 -0500

Seen: 1,704 times

Last updated: Jan 15 '14