- #1
awvvu
- 188
- 1
I'm interested in determining the trajectory and spin of a ping-pong ball for a project for class. I plan on getting a decent resolution video camera and record the ball (with the camera stationary). Afterward, I'll analyze the video on my computer.
My question is: what kind of algorithm can I get more (detailed) information about so I can go about implementing it myself? What kind of things should I search for to find more information? I have a lot of experience programming (in script languages though), so I think I can pull it off. I realize it's not an easy task though. (and it's really not a big deal if I can't get it to work).
I think if I color the ball a really distinctive and bright color (and do some sort of striping to be able to analyze its spin), it wouldn't be terribly hard to do. I can probably do it a brute-force and slow way by analyzing frame-by-frame and comparing it with previous ones, but I'd like some suggestions before I start hacking away at it.
I also reckon I'll have to figure out how to implement some basic depth perception, but I think that can be determined from knowing the (x,y) coordinates on frame and the apparent size of the ball. Then with some calibration based on my video camera placement, I can approximate its coordinates in three dimensions.
(I wasn't sure which forum to place this in exactly.)
edit: Hrm, I just found a library for computer vision, opencv, which looks like it'll be useful for this.
My question is: what kind of algorithm can I get more (detailed) information about so I can go about implementing it myself? What kind of things should I search for to find more information? I have a lot of experience programming (in script languages though), so I think I can pull it off. I realize it's not an easy task though. (and it's really not a big deal if I can't get it to work).
I think if I color the ball a really distinctive and bright color (and do some sort of striping to be able to analyze its spin), it wouldn't be terribly hard to do. I can probably do it a brute-force and slow way by analyzing frame-by-frame and comparing it with previous ones, but I'd like some suggestions before I start hacking away at it.
I also reckon I'll have to figure out how to implement some basic depth perception, but I think that can be determined from knowing the (x,y) coordinates on frame and the apparent size of the ball. Then with some calibration based on my video camera placement, I can approximate its coordinates in three dimensions.
(I wasn't sure which forum to place this in exactly.)
edit: Hrm, I just found a library for computer vision, opencv, which looks like it'll be useful for this.
Last edited: