Ask Your Question

# Revision history [back]

You've asked a fairly complex question, so instead of trying to give you the complete answer, I'll point you in the right direction (based on my limited perspective on the problem you are trying to solve).

Using Camshift, you can find an object center, size, and orientation. Finds an object center, size, and orientation. http://docs.opencv.org/modules/video/doc/motion_analysis_and_object_tracking.html?highlight=camshift (and you'll see other operations here that will be of benefit)

1. Find a reference object. This assumes you can detect an object with OpenCV (or will investigate how to do it).
2. Once you rotate the camera (in one axis I'm assuming), find the same object and run Camshift on it. The orientation should give the value you can utilize.

I don't know if you are trying to solve a more difficult problem and may need to bring in Jacobian Matrices (though probably not if you take the approach of finding a reference object again (could be the same one in some circumstances)).

You've asked a fairly complex question, so instead of trying to give you the complete answer, I'll point you in the right direction (based on my limited perspective on the problem you are trying to solve).

Using Camshift, you can find an object center, size, and orientation. Finds an object center, size, and orientation. http://docs.opencv.org/modules/video/doc/motion_analysis_and_object_tracking.html?highlight=camshift (and you'll see other operations here that will be of benefit)

1. Find a reference object. This assumes you can detect an object with OpenCV (or will investigate how to do it).
2. Once you rotate the camera (in one axis I'm assuming), find the same object and run Camshift on it. The orientation should give the value you can utilize.

I don't know if you are trying to solve a more difficult problem and may need to bring in Jacobian Matrices (though probably not if you take the approach of finding a reference object again (could be the same one in some circumstances)).