Stereometry
We can see in three dimensions because we have two eyes, with one eye seeing a slightly different scene than the other. The two images of the scene are taken with a horizontal offset that is the distance between our eyes. In this activity, we will simulate how the eyes see three dimension with two images, or stereo vision.
There are two ways to do stereo imaging. We can use two identical cameras separated by a distance b from each other. Alternatively, we can use just one camera and move it by a distance b. For practicality, we went with the second option.
Two images of the object are taken. The second image is taken by moving the camera horizontally by a distance b apart from the location where the first image is taken. The vertical position of the camera was maintained at a constant height. The same camera settings were used for both images.
Figure 1 shows the geometry of the setup.
Using similar triangles, we can see that:


Solving for z gives us:

If we do this for many points, we can reconstruct the 3D surface of the object.
The calibration of the camera was done in a previous activity, and the focus was determined to be f = 1063.6 pixels. The distance b is b = 10cm.
The 3D object used here is a box, covered with graphing paper such that it will be easy to correspond the points on the surface. Figure 2 shows the two images captured with the camera displaced a distance b.

The z values are calculated for each point following the equations above.
Figure 3 shows the reconstruction of the surface.
The 3D surface of the box is rendered, shown in Figure 3. The reconstruction was successful, the 3D shape of the box can be recognized. I give myself 9 points for this activity.
Thanks to Kaye and Miguel Sison, my groupmates in a previous class where this activity was previously done.
0 comments:
Post a Comment