Menu

descriptiongroup2

Valentin Dallerit

Group 2

Project presentation

We have to realize a 3D scanner, with common materials, which is enough precise to restitute , rebuild different simples forms. The parameters must be easily modifiable in the user’s interface. The final file must be a Wavefront file with an .obj format.The file must be in scatter form. With this file the user could be able to use it in Blender, a 3D manipulation hardware, and to handle it.

To realize this scanner we must use : a webcam, a line laser, and a rotating table.

The specifications, given by the client are:
-Firstly, if the camera isn’t connected the program ends.
-Secondly, the program must offer in the user’s interface the choice of the parameters of the final file.
-Thirdly, all the useful parameters of the scene and concerning pthe scanner’s precision must be modifiable in the user’s interface.
-Fourthly, a ball has to give a 3D i representation of a ball.
-Fifthly, a parallelepiped rectangle has to give a 3D representation of a parallelepiped. In general the program must give the most approximate form of every simple object it scans .
-And seventhly, the final file of an object has to contain more than twenty thousand points.

Of course the program can be improved by every student's ideas. And if we have time, we can build another version of our scanner.

Works repartition

At the beginning, we had no idea of how to do this program, we only knew that there were two parts :
-The object's capture and the extraction of the laser's position.
-The handling of the rotative table and the convertion of the positions from the laser on every picture (in 2D) to a 3D image.

So we decided, a little randomly, to give the first part to Sven and Thomas, and the second to Valentin and Romain. So each group worked separatly on its own part. The goal of this separation is that the project must progress faster, because, each subgroups can specialise itself in their own part of the code.

You can find the progress and the detail of the subgroups from this link below :

The object capture and laser extraction

The handling of the rotative table, and coordinate conversion

Schedule

At the first session we had a lesson about the HSV technique and how to found a colour on an object. The second parts of this session was in the computer room, we have learned how to use visuastudio and all its functions, like the 'debug' or how to create a project and include all the librairies used or headers, or find the help alone. Secondly we have used several functions used to handle the camera like « cvCaptureFromCam », function which take a picture from the camera. We learnt how to handle the camera, and M Barkowsky gave us the list of all the functions needed for this part. We have learned to use the opencv librairie to gain time during the programmation. Obviously, we often needed help, and teachers explained all we did not know.
Finaly we have written the part of the code which gives an acces to serial port to begin the handling of the rotative table.

During the second session we separated in two subgroups. As we say upper, Sven and thomas are in charge off programming the part of the code which detect the laser's track, while Valentin and Romain work on the part of the code which convert the 2D coordinates to 3D coordinates. Valentin and Romain gave to the other subgroup the part of the code which they had written before. Each subgroups, at this moment began to work separatly. During this session Valentin and Romain have taken over the rotative table and measured that the rotative table do a turn in 2228 steps. After that we began to refecf on the main problem of this subgroup, the relation between the 2D coordinates to 3D coordinates. M Picarougne said to us that we must begin to find the relation to 1D to 2D coordinates.

The third session, we spent our time to find the right version of the relation which give the 3D coordinates. When we get it, M Picarougne saied to us that we have ton consider the rotation. We ommitted that part of the calculation. But afet one hour M Picarougne gave us the relation.

The fourth session, we have written our relations in the piece of code we had already written. As the relation had been found during the last session, the harder part of this work was done. So we wrote our code. But at this point we did not know that we have to write precisely our code and we wrote it in a disorderly maner.

The seventh session each group has its code correctly written. Each function can be selected and copied in our main. So during this session we have began our experience, but during the first scan we get a wavefront file heavier to use it.
We also have began our documentation on sourceforge. Indeed, each group has its own page, and you can discover the project deeper on our two subrgoups pages. Each page described the operation of any parts of our program.
To explain the code easily the program is commented with the doxygen synthax.

The morning before the eight session we were in polytech to correct all problems. We began by fix the scene. We measured the opening angles of the camera. And we measured all the datas needed by the program to do the calculation.
So we executed the program. After resolved all the implementation problems, we discovered that we had an other problem. The program gave us wrong coordinates.
So during the session we found the error, which was in the relation of the 3D coordinates.
The next morning we went back to polytech to finaize our scanner, because we had not the time to scan precisely ours objects. So we finalised our scanner during the afternoon by the user’s interface.

Progress

Currently the program is finished, and you can find the last version of our code on our page.
The Code is commentated with the doxygen synthax.