First of all, I don't have much experience with photography. If I ask something stupid, please accept my excuses.
I'm a self-taught amateur OpenGL programmer. In my job, we have a 360º-panoramic viewer that displays a panorama as a cube-map taken with a Ladybug camera ( composed by 6 sub-cameras, each one will produce one side of the cube ).
Now, I've been asked to check whether we could measure real-world lengths in the panorama. For example, if in a room we have a 3 meter long table, then measuring the table in the photo would tell us it's 3 meter long.
I can retrieve the mouse cursor position in model coordinates, but I can't relate them to real-world coordinates. Using my previous table example:
Table width goes from (0,0) to (3,0) -> 3 meters
Model width goes from (0,0) to (0.356) -> 0.356 unit-agnostic ( pixels? mm? )
I can get the FOV
of the panorama viewer and information regarding the clipping planes and any transformations applied in the viewer (like rotations of the model).
Moreover, for every Ladybug shot (which translates in 6 pictures) I have the camer'as positional information:
Camera's Origin vector at the time of the shot (in UTM coords).
Camera's Direction vector at the time of the shot.
Camera's Up vector at the time of the shot (in UTM coords).
Camera's Roll, Pitch and Yaw values at the time of the shot.
I've been researching through this network and most likely I'll also need the camera's focal-length and sensor size, in order to retrieve the camera's distance to the model, but I'm still researching this topic.
So:
Is it even possible to measure lengths in a picture/panorama?
If it is possible, where can I find more information about this process? I'm not asking for a ready-to-go solution but for guidance in this topic, as I lack the proper background to relate one variable with another.
distance from camera
. If I'm taking a photo of a, say, bottle, the distance is from the camera to the bottle, right? But, if I'm taking a landscape picture or a pano, what point should I take as the "target" to measure the distance? \$\endgroup\$