# Find the XYZ for an object in the sky with two cameras?

This topic is 3147 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

Hi! I have two cameras watching an area in wich an object will appear. One of the cameras is aimed from the side and the other is aimed in front of the object. I have XYZ positions for the cameras and when looking at the images I can calculate the azimuth and elevation to the appearing object. Any ideas how I can use this to calculate the XYZ position for the appearing object?

##### Share on other sites
Well, you can think that one camera gives you the position in XY plane and the other in YZ plane. If the cameras are exactly orthonormal to each other, deriving the general position of the object is relatively easy.

If the cameras are positioned like a pair of eyes, you need to do some shape recognition on the images to find correlating points on both, and solve the perspective transforms based on those points. Then, transforming the points by the [inverse of the perspective] will result in view-space xyz points. Finally, transform the points by the inverse of the [camera position and orientation] to arrive to world-space xyz.

##### Share on other sites
if you have 3D cameras, you can compute the ray firing from each camera towards the object.

That gives you two rays, that you can test for intersection. They will likely not intersect exactly, but you can then compute their 'closest distance' vector and take the midpoint.

##### Share on other sites

http://local.wasp.uwa.edu.au/~pbourke/geometry/lineline3d/

Very helpfull, i have somewhat of a working solution now.

1. 1
2. 2
Rutin
18
3. 3
4. 4
5. 5

• 9
• 14
• 9
• 9
• 9
• ### Forum Statistics

• Total Topics
632921
• Total Posts
3009212
• ### Who's Online (See full list)

There are no registered users currently online

×