Dear DAVID Community,

As you are probably aware, the entire DAVID company, team and product range has been integrated into HP Inc.
This forum is now read-only. Relevant content has been migrated to HP and merged into HP's Support Forums on November 1, 2016.

To start new discussions for 3D Scanning, please register and post your new topic at the HP Support Forums

Creating Stereo data in David 4 with two cameras

Problems, solutions and discussion about scanning with a video projector and stripe patterns.

Creating Stereo data in David 4 with two cameras

Postby Noefrat » Tue Aug 23, 2016 4:43 pm

Hi everyone,


I want to share my problem about using two cameras. I am using David 4.
My aim is to collect ground truth stereo data. So, here is what I need:
- two pictures
- the two associated 3D maps
- the intrinsics of both cameras
- a transformation matrix M12 to pass from the first camera coordinates system to the second one

The matrix M12 allows me to map any point in the image 1 into the image 2.

My problem is that I do not manage to compute the correct transformation matrix.
My questions are:
- in which coordinates system the "Shape Fusion" tab gives the reconstructions? camera or world (=calibration pattern) system?
- any idea of how I can obtain this transformation matrix?


Here some information about what I did:

1. Setup
As I want stereo data, I am using two cameras and I use the David 3D software to acquire the 3D of a same object at the same place, but with two different points of views (Cam1 and Cam2).
The distance between the two cameras (~10cm) is set by the fact that I want narrow baseline.

2. Collecting Data
Both are calibrated with the calibration pattern ***at the same place***.

Why do I calibrate the two cameras with the same calibration pattern at the same place?
According to http://wiki.david-3d.com/calibration :
"the world coordinate system is the same as the calibration pattern coordinate system. "
I thought this will simplify my problem.

In the "Shape Fusion" tab, I noticed that the 2 scans are shifted.

One question is: in which coordinates system the "Shape Fusion" tab gives the reconstructions? camera or world (=calibration pattern) system?

In spite of this shift, I decide to move on.

3. Changes of coordinates system
According to this post: http://forum.david-3d.com/viewtopic.php?f=15&t=6178
"You can interpret them as a 4x4 homogeneous transformation matrix (add bottom row "w", always: 0 0 0 1) which represents the position and orientation of the camera/projector."

Actually, I am using Matlab to prepare this data:
- using the two camera.xml files, I computed the transformation from world to Cam 1 (T_w_to_c1) and Cam 2 (T_w_to_c2)
- I extracted the meshes of the two .obj files and I put the 3D points into their respective camera coordinates system
- I projected the points of the view 1 into the world coordinates system using inv(T_w_to_c1)
- I projected the points of the view 1 in the the world coordinates system into the second camera coordinates system using T_w_to_c2
- I projected the 3D points into the image of the View 2 using the intrinsic parameters of Cam2
However, I keep noticing a shift.

Do not hesitate to ask me more information,
Thanks in advance,


Regards,
Noefrat
 
Posts: 13
Joined: Thu Jun 16, 2016 2:12 pm

Re: Creating Stereo data in David 4 with two cameras

Postby drndadoo » Wed Aug 24, 2016 1:45 pm

This is a very specific question. Calibration panels are coordinate system in DAVID, I am not 100% sure but i think that fusion is done in same coordinate system as scanning, but I will check this one.
Transformation matrix is for me something new, sorry :idea:
drndadoo
DAVID Support
 
Posts: 194
Joined: Tue Mar 24, 2015 3:09 pm

Re: Creating Stereo data in David 4 with two cameras

Postby Noefrat » Mon Aug 29, 2016 3:11 pm

If I can use David 4 again (I have some licence problems), I will post a picture of the Shape Fusion with the two scans.
However, when I created this post, I noticed that a new version was released and that it proposes stereo scanning, which, I think, can make the job for me.

Is it possible for David 5 to answer to my problem?

"I am not 100% sure but i think that fusion is done in same coordinate system as scanning"
If you think this, I will try to make this experiment one more time.
Noefrat
 
Posts: 13
Joined: Thu Jun 16, 2016 2:12 pm


Return to Structured Light Scanning

Who is online

Users browsing this forum: No registered users and 1 guest

cron