# Revision history [back]

### Triangulate Points from Stereo Image

Hello guys,

I hope someone can help me with my problem :)

That's my approach

I have two cameras and now I want to calculate the 3D coordinates of an object. For this, I calibrate the cameras individually and then I use stereoCalibrate.

Now I have the intrinsic and extrinsic parameters and would like to triangulate. To do that, I create the projection Matrices like this.

Basically one camera I can keep as P1= K1 [I|0] (identity rotation and 0 translation), and the other camera P2= K2*[R|t] (rotation and translation between the cameras from stereoCalibrate())

These matrices I hand over to the triangulate function (http://www.morethantechnical.com/2012/01/04/simple-triangulation-with-opencv-from-harley-zisserman-w-code/)

To test the triangulation

Checkerboard: 9x6 and 12 mm per square

I use the reference checkerboard images because the depth should be constant but i have depth "linear". The x and y coordinates are accurate over the entire distance to 0.2mm.

The picture shows the values for the first two rows

Anyone know where is my problem? Thanks.

### Triangulate Points from Stereo Image

Hello guys,

I hope someone can help me with my problem :)

That's my approach

I have two cameras and now I want to calculate the 3D coordinates of an object. For this, I calibrate the cameras individually and then I use stereoCalibrate.

Now I have the intrinsic and extrinsic parameters and would like to triangulate. To do that, I create the projection Matrices like this.

Basically one camera I can keep as P1= K1 [I|0] (identity rotation and 0 translation), and the other camera P2= K2*[R|t] (rotation and translation between the cameras from stereoCalibrate())

These matrices I hand over to the triangulate function (http://www.morethantechnical.com/2012/01/04/simple-triangulation-with-opencv-from-harley-zisserman-w-code/)

To test the triangulation

Checkerboard: 9x6 and 12 mm per square

I use the reference checkerboard images because the depth should be constant but i have depth "linear". The x and y coordinates are accurate over the entire distance to 0.2mm.

The picture shows the values for the first two rowsrows. As you can see the depth is strange

Anyone know where is my problem? Thanks.