Hi, I searched many of answer blogs but didn't help. So I'm here.
I'm trying to get the depth info of a ball on the flight. I'm using openni and opencv2 on ros groovy. I'm getting a weird segmentation fault when I run the node. I'm calculating the center of the ball using cv::findcontour and then largest contour area. If I start the node keeping the ball inside the image frame, I don't get segmentation fault until I move the ball out of the frame. Again, If I start the node keeping the ball out of the frame, I dont get segmentation fault until I bring the ball inside the frame. The node is given in the following link http:codepad.org/wnC4VWu8
Can anybody please help? Thanks in advance.