Dart Board Program

Mar 1, 2015 at 2:25am
Hello.
I am thinking about making a dart board scoring program. The biggest obstacle I can think of is making the dart board to click on and get different scores depending on what section is clicked. I'm using C++ Builder XE7. First is this the right place to post such a question? If so does anyone have any ideas? Thanks.
Greg
Mar 2, 2015 at 2:45pm
put image on form, register onMouseClick event and use received X,Y coordinates to calculate points clicked. Use label to show point count.
Mar 2, 2015 at 3:29pm
Sounds like a plan, but there are hundreds of x,y coordinates. Is there an easy way to find out what slice of the pie and section it belongs too? Maybe by color? Thanks!
Mar 2, 2015 at 6:48pm
The winapi function GetPixel() will give you color of the pixel at a given coordinate.

https://msdn.microsoft.com/en-us/library/windows/desktop/dd144909%28v=vs.85%29.aspx
Mar 2, 2015 at 8:17pm
Thanks I'll look into it, and see if I can get something working.
Topic archived. No new replies allowed.