mardi 29 décembre 2009

Week 11 [21/12 to 27/12]

Work Of The Week



This week was the first Christmas Holiday week. For those 2 week break I prepared a list of tasks I should complete for the project. I update the list during the work also, when new detailed tasks was needed. There was around 20 points to be done, and 13 of them were completed.

The complete list is:

  1. Modify the loading process for OBJ
  2. Add "save normals" options for OBJ
  3. Scale the loaded mesh
  4. Remove the unused "edge" component of a face
    • from Loader
    • from Saver
  5. No double error message when Loader display an error
  6. Rewrite the tooltips of the CameraWidget when the settings changes
  7. Use the translation precision setting
  8. Finish the picking in OpenGL: end up with a unique selection from the mesh
  9. resolve the MeshWidget and the dock resize defaults (mainwidget over the dockwidgets)
  10. Update the settings widget
    • change from a tab to another
    • save and save all
    • reset and reset all
    • default and default all
    • colour and light page
    • no default button to allow enter key to be pressed
    • default values for camera to be used
  11. Find segmentatio fault in loading
  12. Add warning handling for Tasks
  13. Modify the current text format to only load points => real point cloud loading and adapt widget for it
  14. modify the point size in OpenGL

  15. adapt the code to avoid language translation redundancy


  16. add warning if extension name is empty on saving


  17. recognise a triangulated OBJ file


  18. WorkInProgress widget to inform that a task is running


  19. add time information for the task


  20. run another editor from the original one and load in another editor


  21. update the display after closing


And finally the summary of the week work! This week I mostly work on a new process organisation, in order to be able to create a parallel thread more easily to handle a separated action (as loading, saving and later running an algorithm)> It took time to understand how to work with the QThread class, because some points were not obviously explained in the documentation. But after few researches and tests, I managed to create a threaded class called Task, and make the Load and Save classes to inherit from it. In further development the algorithms used to modify the mesh will also inherit from the Task. Creating another thread to handle external processes allow the display thread to continue its job, and avoid a "freezing" look to the interface while a time consuming action is performed.

I also spend a lot of time just after this work to find a segmentation error, caused by a sneaky part of the code, that I taught I wasn't using.

Total worked: 18 hours.







Multiple modifications


I handle the new OBJ loading process, using standard C functions instead of the QString and streaming technique used before. The result is a less sensible loading process, that do not care about spaces between values for example. It now allow all type of OBJ definition to be handle without (normally) causing dangerous troubles. Quad mesh are loaded as Triangulated one, resulting in a strange looking mesh but do not create dangerous failure for loading. Completion of point 1.

Various modification were made on the CameraWidget and MeshWidget to re-distribute tasks. The first scaling code adaptation was done, resulting in strange translation and near/far problems. Was cancelled because causing segmentation fault.

Several modification were made on the interface, mostly to correct few illogic option display and adapt the choices from the settings. Cleaning of the MeshWidget code.

Adding warning handling - task 12 completed

Time worked:
9 h 30

Adapt both Loader and Saver loading and saving function to remove the edge (that is unused) component. Modify the FileSearchWidget to handle the correct option accordingly to the chosen format.
Time worked: 1h



Task: a threaded action



The creation of the threaded task was done in common with the WorkInProgressWidget, as both are related to display the running activity. The main difficulty was to understand the QThread running process to handle the Qt events. Thus it was not difficult to copy the code from my referenced website (see further) but some errors appears just after that. The segmentation fault source was unknown until the 29/12 (week 12).

Time worked:
3 h 30
Segmentation fault search. Not an easy task because it was not thrown when the application was run into the debugger. No solution was found.Time worked: 5 h

Information And References



To use the QThread I used a good explanation from Harold Hunt blog but a also used the previous posted OBJ definition to verify my loader compatibilities with the OBJ standard.

lundi 14 décembre 2009

Week 10 [07/12 to 13/12]


Work Of The Week



This week the loading and saving processes were threaded, in order for the application to not looks like freezing when doing such tasks.

And I started to work on the picking process, thinking of it more precisely and beginning the OpenGL part of the process.


Total worked: 7h hours.




Threading the loading and saving



Basically the idea was to change the static classes Loader and Saver to normal object that extend the QThread one. Then some attributes like the file format, the filename and other details were added to the constructor.
The QThread class invokes the run method in a new thread, separate from the display one when start is called. That suppresses the freeze looking of the GUI when loading huge files.

Finally the MainWindow was adapted to handle such new object, allowing only one loader or saver thread in the application.

Time worked:
2 h 30

Picking in OpenGL



The basic of the picking process was developed. To resume it briefly the SelectionWidget can now handle two type of original data: a NormalizedMesh and a Selection. The first one is the pointer to the original data, and the second the current part to display. If no selection object is there it means that it is the original mesh. Later on the MeshWidget will catch user clicks to send new vertex identifier to the current SelectionWidget that will update its Selection object.

For the moment the Selection class was created, with a full bunch of functions. It is two hash maps of vertices and faces indexes that contains boolean values. If it is true it is in the selection.

I also begin to work on the selection process in OpenGL and done most of it. But no signals are sent yet to warn the SelectionWidget of the modifications (such as no vertex index are return due to a little trouble - the mouse coordinate mush be taken from the MeshWidget coordinate and not the overall application).

Time worked:
4 h 30

Gantt State


No very big news about the Gantt, unless I will be late again soon as my courseworks are taking me more time than expected.


Information And References



This week I read a little about picking in OpenGL, and the previous published websites were used. Nonetheless I also found some information on the following one: Computing normals to achieve flat and smooth shading




Next Week prevision



Next week work will certainly be null as it is the last week for one of my biggest coursework. It takes much more time than expected (I planned 10h on that work and it almost took me 15h and not half is done).

lundi 7 décembre 2009

Week 09 [30/11 to 06/12]


Work Of The Week



I worked quite a lot this week, mostly because I enjoyed it and had time. The interface part was, after all, far more important than expected.


Most of the work was adaptation. I introduced the final architecture for the software, or most of it, this week, and therefore needed to modify most of the interface to make it work.


The other main part was the introduction of the NormalizedMesh that is, as its names indicates it, a mesh that handles shaded view and lightning. It also handles the Wireframe view, that was first part of the SimpleMesh organisation.


As it's been a long time I didn't post a version of the software on that blog, and as the current version is almost finished (for the interface point of view) you can go on my sendpsace to get both sources or win32 executable (that includes sources as well).




Total worked: 23 hours 30.




Adaptation


There is a lot to say about the adaptation, as it was in fact multiple adaptations. Most of them concerned the MeshWidget that were handling most of the operation that it now delegate.


First I continue to work on the CameraWidgwet (that is the camera dock in the interface) and therefore needed to modify the MeshWidget to use it as the centre of all the view informations (translation, rotation are saved in that widget, the MeshWidget is just the user action listener).

Time worked:
1 h 30

Then I introduced the SettingsWidget, that is a window to save, load or reset the global default settings. It is using the QSetting object, that permit to be system independent (saving on the registry in Windows, in XML files for OS X and configuration files for Unix). This required some work, more than expected, and will need some few review before the end. Otherwise it is almost finished.

Time worked:
8 h 30

I created a new type of button: the ColourButton that represent a colour choice, shows it, and allow the user to re-define it by click on it.

Time worked:
1 h

I finally added the last widgets: the SelectionListWidget and the SelectionWidget that are both really important. The second one will handle the whole display machine, containing a selection or the original mesh. The first will contain the list of selection and display it. For the moment only one selection is allowed: the loaded mesh, but it will evolve to more soon. I needed to adapt most of the Interface components to deal with that new architecture, as the MainWindow and the MeshWidget were the most concerned.

Time worked:
4 h

Little and simple work, but I created the icons picture for the interface. They are not pretty but are, as far as I known, obvious.

Time worked:
1 h

NormalizedMesh and the shaded view



This was the most important modification of the week, as it makes me change most of the current code. The changes were smalls, but very important. And some revisions will certainly be needed to improve the current software.


First of all I created the object itself, that is a sub-class of the previous SimpleMesh. Now, as SimpleMesh is just a point cloud representation. The whole faces are handles by the NormalizedMesh. I also worked on the faces and vertices normals computation, and thanks to a good website listed bellow I was pretty much quick. I think I will adapt the algorithm for the vertices computation, as it looks pretty much time consuming for big meshes (doing too much loops that could be avoided by some indexing). This works also contains the adaptation of all the interface object that were using the SimpleMesh to handles the new functionalities.

Time worked:
6 h 30

Project Structure



This work was basically adapting the .pro, that represents a Qt project. This files handles the creation of the Makefiles, and contains all the information about the project itself (source files, designer files, resources, ...). I updated it in order to have a better organisation, and to handle the "install" process that will create a folder with all that is needed to run the software.

Time worked:
2 h


Gantt State



I didn't publish a Gantt chart since a while. It didn't changes a lot. I just make the current task to run longuer (interface creation) as I had some delays and as it takes more time that planned. However the delays are not important at all, and I still have some free time between the second part planned end and the begining of the report writing.




Current task:



General view:




Information And References



I didn't read a lot for this week work, even if I worked a lot. Most of it was Qt documentation.


I used several good websites to understand the normal computation. It is barely simple:

The first one was the one I used to understand more in details how the normals are computed, and the second one was used for the coding part. I mostly copied the code, and adapt it for my purposes.

Next Week prevision

The interface main actions are almost finished. Was is left is the picking part, that is a milestone in this part of the software.

I will also work on a multi-window software (create one new window by loaded mesh).

If I have time I will also work on the loading and saving process, to be handle by threads, in order to do not make the application to freeze during long processes. I will also try to make a special "work in progress" widget that will display few messages and a progress bar about a current time-consuming work.

  • OpenGl picking with Qt
  • Multiple window soft
  • Work in progress widget for loading and saving processes.

mercredi 2 décembre 2009

Week 08 [23/11 to 29/11]


Work Of The Week



This week I worked less than expected. I mostly adapt the existing code to finally have its namespace structure and create the Camera widget for the interface.



Total worked: 6 hours 30.




Namespace adaptation



This work wasn't difficult, but needed to be done. I didn't write any namespace during the past weeks and therefore modify all the files. I also added the licence text in each file. All the software is under the LGPL.

Time worked:
1 h 30

Camera Widget



I created the widget with the Qt designer, as for the others widget. But this one created troubles as a lot of signals and slots needed to be create (one per option, plus others). It also required linking with the MeshWidget object to update the values and get the user interactions. I didn't connect all the actions, just the rotation. But I will do that further on.

Time worked:
5 h


Gantt State



Still no Gantt state... As I need to adapt it for the few time lost last week and didn't take time to do so.



Information And References



The only reference that is related to this week work is the LGPL website: www.gnu.org/copyleft/lesser.html





Next Week prevision



Next week I will continue to work on the Camera widget in order to finish it, and may begin to add new OpenGl features like lightning (as Eyad asked for it during our last meeting).



  • Continue the Camera widget adaptation
  • lightning for OpenGl

mardi 24 novembre 2009

Week 07 [16/11 to 22/11]


Work Of The Week



This week I didn't work so much because my laptop past out. It then takes time to buy a new one and ask for a computer in RGU facilities in order to work.


But I worked a little on OpenGl picking, just doing some researches. I also begin to adapt the interface to handle translation. The main work was on the creation of an Exception class that will display an error message.



Total worked: 3 hours.




Adding the translation



Not so much needed to be done, just few lines to modify the drawing matrix and few researches on Qt way of handling key pressed and released events.

Time worked:
1 h

Creation of Exception class



This was a little more longer than expected, and not fully finished (documentation need to be written). But I use it for the OBJ loading process, and it is almost ready for other tasks exceptions (a little code adaptation need to be done, instead of throwing 0 must throw an object).

Time worked:
2 h


Gantt State



No Gantt state this week, as no real evolution happen.


Information And References



Same as usual for the Qt documentation, and the following websites for the OpenGl picking:






Next Week prevision



Next week is the coursework week in the School of Computing, but I don't have too much courseworks yet. I will certainly continue the current tasks, that is code adaptation for new features. I should provide new interface widgets and actions soon.



  • create a namespace structure to separate the code
  • Add the latest features (camera window, selection window, settings, ...)

mardi 17 novembre 2009

Week 06 [09/11 to 15/11]


Work Of The Week



This week I worked half of the time on the design, and the other one on the beginning of the development. The result of the design is a document that summarize my first choices for the object organisation and also for their interaction. You can get the result of the development windows 32 binaries, the software is working, and no major bugs were found for the moment. If you want the sources just contact me by email.


I changed my sendspace folder as public, so now you can access it or follow the RSS feed to get all the documents.


Total worked: 16 hours.



Design



Most of the design work was about creating the final document and finish the drawing with Bouml. It tooks time, but give a satisfactory result. Moreover if it evolves during the development time, some changes could be done on Bouml fairly easily.

Time worked:
5h30

Development



The development was almost adapting the previous code, done as a prototype, in order to follow the UML class diagrams. Then I used the Qt Designer to create the first GUI and link it with my code. All was not very difficult, but is time consuming (learning a little about Qt Designer, that I almost never used). The result is a easy to develop interface, that needs few code creation. At this point the software has a basic interface and can load or save several type of file format (text and OBJ).

Time worked:
10h30


Gantt State


As the Gantt diagram shows it I am in advance of 1 week over the schedule. Basically this is due to my current work, that wasn't faster than expected, just that I worked more than expected. But as next week is the assessment week I will, may be, work less on the project. Anyway the left part of the interface isn't the easier one: the selection mechanism.




Information And References



I didn't use so much references that week also, instead of the Qt documentation.





Next Week prevision



Next week I should focus myself on the last parts of the interface creation. In order to follow what was said in both Gantt and the design I should:


  • handle translation of the view
  • learn an try to use the OpenGl selection mechanism

I will certainly do the first part, but will only begin to work on the second one if I have enough time.

mardi 10 novembre 2009

Week 05 [02/11 to 08/11]

Work Of The Week


This week work was shared between the writing of a document that will certainly be inserted in my final report and continuing the design. I wrote the whole "choice" document, available here, and almost finish the UML drawing.


I have, for the moment, several class and sequence diagrams to illustrate some of the basics possible actions. In fact just two Sequence diagrams are missing in my list: the selection mechanism and the saving into files. The first one needs more research on how OpenGL handles it, and the second was almost not done by lack of time. I begin to write a little document that will contain all the design of the project, or the most it can, in order to publish it here.


Total worked: 11 hours.



The choice justification



Writing this document was almost just putting my note to a clean an ordered document. But as it goes further I needed to insert few references, most of them are websites, and write some descriptions about tools and other possible choice that could have been made. The global result of that is a document that present most of the choices I made, and explain them.

Time worked:
5h30

UML drawing



I draw several different diagrams during the week.

3 class diagrams:
  • a relation diagram
  • the detailed base package
  • the detailed interface package
several sequence diagrams:
  • MainWindow's creation
  • Image loading
  • Vue modification
  • display mechanism
  • changing the background colour
All will be explained and detailed in the design document that will be published at the end of the design part. But, as a preview, you can see the relation class diagram:

Class diagram: relations


Time worked:
5h30


Gantt State


The current state of the project is still the design part. All is going as it is planed, even if I was thinking of going to fast in the beginning of the project. Because even if some part of the next steps are already done, the further adaptation that will be needed for the adaptation of the UML diagrams will take time. In other words the little programming work I done as a prototype wasn't a losing of time, it permitted to give me better ideas on how I have to implement the whole structure.


One task isn't totally finished yet: the interface drawing. All that need to be done is simply to clean and scan the drawings.



Gantt diagram


Information And References



I did use quite a lot of references this week, mostly tools website, to write the choice document. But for the UML drawing none of them were necessary, as Bouml provide most of the tools I needed, and as I was familiar enough with the class and sequence diagrams to do not need to refers to books or websites.





Next Week prevision



As the Gantt diagram shows it next week will be the end of the design part of the project. I will publish the design document here, that will summarise all the work that have been done in this part. Then the implementation part will begin, with the interface and core development.



  • finish design and publish the result document
  • begin the implementation part

lundi 2 novembre 2009

Week 04 [26/10 to 01/11]

Work Of The Week


This week was basically the end of the Requirements definitions. Additionally work was done to improve the document, and it was finally published on Friday (you can download it here).


During this weekend I had some time left to read and adapt my previous code (done for CM3030: 3D Graphics Using OpenGL And C++):

  • to use Qt as Graphic Interface and not Glut
  • to load obj files instead of 3DSM files or simple text files.
And basically I succeed the first point, but still have few trouble with OpenGL function I did know. The second point is a bit more complicated, and after the deployment of my basic set of classes, is now almost done. But still more need to be done in the two points to have a clean code that will be ready to be integrated in an evolved GUI.

You can have a look on what I've done by downloading the current software that is not documented or even bug free, but it will give a good preview of what I've done so far. As the current work isn't yet finished, no sources are provided, but I can send them on demand.


Total worked: 13 hours.



Requirements



Work on the document itself, excluding already finished functional requirements.

Time worked:
2 h

Correction and adaptation of the document following Eyad's advices:
creation of the Optional Part, few simplifications on the lists for non-functional objectives, introduction and glossary work.

Time worked:
2 h

Design and Development



Drawing for the interface.

Time worked:
1h

Design and creation of the Basics set of classes (Mesh, Algorithm, MeshWidget, Loader).

Time worked:
2 h

Creation of the main functionalities of the MeshWidget (moving the view with the mouse) and of the Loader object (load form basic text files, and simple OBJ files). Need documentation step.

Time worked:
6 h


Gantt State



The Gantt Diagram above shows that I'm going faster than expected for the design. It is also true that I begin a little of development, as I am using a spiral development schema (design - develop - test - document -> go back to design), But most of the design will be done at the end of the next week I presume.




Gantt State 03/11/09 link


Information And References


Useful read of documentations:




Next Week prevision



The next week work is simple to plan: the current work on loading the files will be paused a little, as the Text loading is working, to focus on the design. Some drawing need to be completed, and UML class diagrams, UML action diagrams will be provided.



  • UML class diagrams (for the base, and interface parts).
  • UML action diagrams to represents the main functions of the interface.
  • Finishing the interface drawing to have a finished "first idea" of the interface.

I should also quickly write to "proper" some discussions about my choices for the project, including technology solutions and used tools. This should certainly come with a first publication about my researches, that were limited for the moment on what is 3D scanner, and some basics about 3D graphics (a mesh definition, and some way of storage, more focused on the OBJ format).

lundi 26 octobre 2009

Week 03 [19/10 to 25/10]

Work Of The Week



The main work area of the week was the requirements. As the researches goes to a point that a focus was needed to be efficient, I stop the process without taking a look furthermore in the algorithms details.


Total worked: 7 hours.




Research



Reading about one of the algorithms used in Denoising 3D Models with Attributes using Soft Thresholding. Taking some notes to understand how that works, but need to work more on it.

Time worked:
1 h

Reading and searching about OBJ file format. Found one good definition of it.

Time worked:
1 h

Requirements


Work on the functional requirements and the creation of the Detailed Requirement document. Using the lecture provided by Derek Shirreffs for the Project Management in a Computing Environment module.

Time worked:
2 h

Project plan creation according to the functional requirements and correction of them after the meeting with Eyad Elyan. The result was the current Gantt diagram.

Time worked:
2 h

Design: Interface drawing


Some first drawing of a possible interface for the software. Simple window looks and some options thinking.

Time worked:
1 h

Gantt State



The Gantt diagram is now "finished" for it first state. It will certainly need some adaptation in the future, but the current state will be referred as the Initial Project Plan.


Edit note: edition of the image after finding that a part wasn't completely drawn.

Information And References



Detailed links that are presents in the above text:

The publication of Michaël Roy, Sebti Foufou, and Frédéric Truchetet: Denoising 3D Models with Attributes using Soft Thresholding


A definition of the OBJ format: obj_format.txt




Next Week prevision



This week is the last one before the submission of the Detailed Project Requirements. Therefore most of the work will be to finish this document and correct it with Eyad in order to have a strong and clear definition of the project goals. As the project plan is finished, the next work could also include the beginning of the design part in the Gantt diagram.

  • finish the Detailed Requirement document
  • begin the design part

jeudi 15 octobre 2009

Week 02 [12/10 to 18/10] Research

Work Of The Week



This week was the beginning of the research part of the project. Therefore the only work was complete my knowledge about the 3D scanners, the possible defaults of these devices and read publication on their resolution.

Total worked: 8 hours.



Reasearch about the project



It was mainly reading about 3D scanners, writing part of the research document I will provide, and finding existing solution for the problems. I almost finished the explanation on 3D scanners, and started to read more about the solutions.

Time worked:
2h

Gantt State


The Gantt diagram isn't for the moment complete. But I provide the initial part, and begins to complete it.

Free Image Hosting at www.ImageShack.us

Information And References


Most of the information I used are from Wikipedia, but I also read in details the publication of Michaël Roy, Sebti Foufou, and Frédéric Truchetet about noise removal on meshes.

3D Scanner definition

Polygon Mesh definition

Denoising 3D Models with Attributes using Soft Thresholding





Next Week prevision



Next week I'll continue to work on my researches. I will document myself more about the development possibilities for my project, and will take a look on what type of scanner RGU has.

  • searching about development tools
  • searching information on RGU device specifications
  • continue the writing of the research document

vendredi 9 octobre 2009

Week 01 [05/10 to 11/10]


Work Of The Week



This week was the Project Proposal week. Eyad and I needs to agreed on the main theme of the project, 3D Surface Data Editor, and I must propose the project to the academical part of the RGU School Of Computing.



Total worked: 4 hours.



Quick researches



In order to propose a good quality project proposal I first of all search informations on obvious problems for 3D surfaces generated by 3D scanners devices. Therefore I found some interesting publications, and use one of them to create the document.

Time worked:
2 h

Writing the Project Proposal Document



This was the work of organising the few information and present them in order to be represents the project goals. It also includes the setting up of the project, as creating a basic Gantt diagram and few other small works (creating this blog for example).

Time worked:
2 h

Gantt State



The Gantt isn't complete at all, therefore I will just show here the milestones I created.


  • [ML] Submit Initial Project Proposal 09/10/09
  • [ML] Submit Detailed Project Specifications 30/10/09
  • [ML] Projects Presentation's week 26/04/10
  • [ML] Submit Report 30/04/10
  • [ML] Demonstration 07/05/10

Information And References



The researches were focussed on 3D surfaces and how to correct defaults, especially noise problems. I also contact one of my French teacher, Thibaut MARZAIS, that publish a thesis on Surface Fitting as his PhD work. I would like to thanks him for the advices and researches advices he gave me, and especially the CGAL library recommendation.





Next Week prevision



After publishing the project proposal document the researches can begins. First of all documentation about 3D scanners will be required to have an overview of such devices. Then listing some typical problems and existing solutions to solve them will be on focus.

Project Proposal and personal details

First of all I will talk about myself, as a student in Computer Science. Then I will develop briefly what is the project about, and who my tutor is.


I am Thomas RICHARD, student in the School of Computing of the Robert Gordon University, in Aberdeen (UK). I will be graduated in the end of 2010 in Computer Science. As it the final year of my Bachelor of Science (BSc) I have to complete a project, submit a report and do an oral presentation of it.


Therefore I contacted Eyad Elyan in the end of the 2008-2009 academic year. He introduces me to the possibility of doing this current project.


As it is now possible to generate, or create, quite easily 3D surfaces - called mesh - it is also important to be able to simplify and improve them. Most of the time a mesh generated by a 3D scanner isn't really usable, it needs some treatments to correct problems. This project will be to create a simple tool that handles some of these solutions.


3D human face with noise 3D human face denoised
3D human face with noise 3D human face de-noised

You can have more details on the subject, deliverables and needed skills in the attached file. But as it is still a project proposition, you will need to wait until the publication of the detailed functionalities of the project's software.


Both pictures are from: Denoising 3D Models with Attributes using Soft Thresholding Michal Roy, Sebti Foufou, and Frdric Truchetet, Le2i - CNRS UMR 5158- Universit de Bourgogne


You can get my Initial Project Proposal PDF file (stored on sendspace).