Ask Your Question
0

Tracking 3D + rotation matrix

asked 2013-04-05 07:53:00 -0500

Ffaten gravatar image

Hi , Does anyone know how need track an object ( a cube for example)? I need as output the x,y,z postion and the matrix rotation of the object

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
1

answered 2013-04-06 04:20:46 -0500

See the POSIT algorithm here to find the 3D position of a known object. To use POSIT, you need to find 2D points and their association to 3D object. You can use an object with different color in each corner, or anything else... The tracking is the most difficult in my opinion.

edit flag offensive delete link more

Comments

Thank you so much , i tried to compile the tutorial code of POSIT it works with only a specific image for a cube : "IplImage img = cvLoadImage( "C:\img.jpg" );". I need image from a capture video not from a known image : "IplImage *img; // capture from video device CvCapture capture = cvCaptureFromCAM(0); // create a window to display the images cvNamedWindow("mainWin", CV_WINDOW_AUTOSIZE);

while(1)
{
    // retrieve the captured frame
    img=cvQueryFrame(capture);..."

and then how can i track the cube and use the POSIT algorithm

Ffaten gravatar imageFfaten ( 2013-04-08 03:16:51 -0500 )edit

As I've said before, the tracking is the most difficult part... Start using a different color for each corner, and after that, if you are not using a cube, you could try different approach, like SIFT/SURF/ORB/.. and find homography like in this tutorial http://docs.opencv.org/doc/tutorials/features2d/feature_homography/feature_homography.html But take care that the object must not be a plane for POSIT!

Mathieu Barnachon gravatar imageMathieu Barnachon ( 2013-04-08 11:40:49 -0500 )edit
Login/Signup to Answer

Question Tools

Stats

Asked: 2013-04-05 07:53:00 -0500

Seen: 1,310 times

Last updated: Apr 06 '13