Difference between revisions of "User:Harman052/GSoc2013/Logs"
|Line 312:||Line 312:|
===September 03 2013===
===September 03 2013===
* Testing the application after
* Testing the application after with signup module. Identified possibilities where improvements can be done; will be added to TODO list.
* Added bootstrap CSS and custom CSS to improve look and feel.
* Added bootstrap CSS and custom CSS to improve look and feel.
Revision as of 11:16, 8 September 2013
Proposal Link: http://brlcad.org/wiki/User:Harman052
- 1 Daily Progress
- 1.1 June 17 2013
- 1.2 June 18 2013
- 1.3 June 19 2013
- 1.4 June 20 2013
- 1.5 June 21 2013
- 1.6 June 22 2013
- 1.7 June 23 2013
- 1.8 June 24 2013
- 1.9 June 25 2013
- 1.10 June 26 2013
- 1.11 June 27 2013
- 1.12 June 28 2013
- 1.13 June 29 2013
- 1.14 June 30 2013
- 1.15 July 01 2013
- 1.16 July 02 2013
- 1.17 July 03 2013
- 1.18 July 04 2013
- 1.19 July 05 2013
- 1.20 July 06 2013
- 1.21 July 07 2013
- 1.22 July 08 2013
- 1.23 July 09 2013
- 1.24 July 10 2013
- 1.25 July 11 2013
- 1.26 July 12 2013
- 1.27 July 13 2013
- 1.28 July 14 2013
- 1.29 July 15 2013
- 1.30 July 16 2013
- 1.31 July 17 2013
- 1.32 July 18 2013
- 1.33 July 19 2013
- 1.34 July 20 2013
- 1.35 July 21 2013
- 1.36 July 22 2013
- 1.37 July 23 2013
- 1.38 July 24 2013
- 1.39 July 25 2013
- 1.40 July 26 2013
- 1.41 July 27 2013
- 1.42 July 28 2013
- 1.43 July 29 2013
- 1.44 July 30 2013
- 1.45 July 31 2013
- 1.46 August 01 2013
- 1.47 August 02 2013
- 1.48 August 03 2013
- 1.49 August 04 2013
- 1.50 August 05 2013
- 1.51 August 06 2013
- 1.52 August 07 2013
- 1.53 August 08 2013
- 1.54 August 09 2013
- 1.55 August 10 2013
- 1.56 August 11 2013
- 1.57 August 12 2013
- 1.58 August 13 2013
- 1.59 August 14 2013
- 1.60 August 15 2013
- 1.61 August 16 2013
- 1.62 August 17 2013
- 1.63 August 18 2013
- 1.64 August 19 2013
- 1.65 August 20 2013
- 1.66 August 21 2013
- 1.67 August 22 2013
- 1.68 August 23 2013
- 1.69 August 24 2013
- 1.70 August 25 2013
- 1.71 August 26 2013
- 1.72 August 27 2013
- 1.73 August 28 2013
- 1.74 August 29 2013
- 1.75 August 30 2013
- 1.76 August 31 2013
- 1.77 September 01 2013
- 1.78 September 02 2013
- 1.79 September 03 2013
- 1.80 September 04 2013
- 1.81 September 05 2013
- 1.82 September 06 2013
- 1.83 September 07 2013
June 17 2013
June 18 2013
Tried tutorials of HTML5 to build base for the project implementation.
June 19 2013
I decided to submit a patch and selected a feature request of directing the mged output to journal file. Currently, only user inputs can be written in it. I tried by searching for files that I need to edit but failed. I was searching for bu_log_add_hook() that doesn't pointed me to files that I could start with. Later I got useful and detailed hints from IRC to look into src/mged. I will look into it.
Also discussed about project scope with Sean.
June 20 2013
June 21 2013
Searched for solutions for unclear aspects of project. Searched about wireframes, why wireframes are used? It is just because they are fast to calculate but didn't find any anything useful specific to BRL-CAD for reply.
June 22 2013
I searched and collected lot of information that can be very useful for BRL-CAD. I am compiling it now, and as it completed, will share with developers.
June 23 2013
Found more useful information. Will share on mailing list, once summarized. Took break.
June 24 2013
Worked on patch. Studied the f_journal function, its various components. Some doubts are still not cleared. Will try to finish by tomorrow.
June 25 2013
- Prepared a detailed email and sent to mailing list about what I found for Sean's questions. Expecting new directions.
- Designed basic layout of interface.
June 26 2013
- As told by mentor, I studied WebGL and tried WebGL demos. I would use mixture of HTML5 and WebGL.
June 27 2013
- As suggested by Charlie Stirk, I reviewed http://shapesmith.net/. I tried it by downloading and installing locally. 3D objects can be easily created and edited. Moreover, it can produce josm files than can be easily parsed and used to make script of MGED commands. It will be wonderful if we use its interface.
- Got reply from Sean, suggesting to shift from making geometry editor to geometry viewer.
June 28 2013
I was suggested to focus on making online geometry viewer. I just posted on dev-mailing list whatever I did in this context.
June 29 2013
- Used facetize command to convert implicit primitives into bot format. However it failed to run on brep objects.
- Searched for web technology that could support NURBS geometry directly.
- Posted details about today's progress on mailing list.
June 30 2013
- Explored source files to fix the facetize command. I found code for facetize command in two files, one in src/libged/facetize.c and other in src/libged/wdb_obj.c. Currently facetize.c is working.
July 01 2013
Wasn't able to do much work due to some un-expected urgent work.
July 02 2013
Looking into wdb_obj.c as it controls BRL-CAD database, it may be helpful in reading file from browser.
July 03 2013
- Completed the task of summarizing the things discussed on mailing list into an wiki article.
- Working on layout.
July 04 2013
Explored src/libged/facetize.c and src/libged/wdb_obj.c files. From man page, found "t" option of facetize command and for corresponding to this option, found nmg_use_tnurbs flag in src/libged/facetize.c and src/libged/wdb_obj.c files. But I didn't found any relevant code that can be hooked to make the command working in desired way.
July 05 2013
- Trying to figure out solution. Ask for solution on IRC.
July 06 2013
- Post problem on mailing list.
- In the mean time, I worked on patch. Tried to add "-r" option (for response) under f_journal function in history file. Now just need to figure out where to add hook in this file.
July 07 2013
- Waiting for reply.
- Found function history_journalize that actually writes data in journal file and where the log hook is required to be added. With the help of grep, I found details about bu_log_add_hook() in bu.h. Need to figure out how to implement.
July 08 2013
Was looking at similar implementation of bu_log_add_hook() in src/libged/log.c and util/pl-dm.c to figure out to redirect data to file. Both these files have same bu_hook_t function. I tried to implement in similar way, but it didn't worked.
July 09 2013
- Model is taking input just like an ordinary webGL application i.e. in the form of vertices and faces, so we can easily provide that with OBJ file.
July 10 2013
- I read about WebGLU. Even they didn't specify the support for visualizing trimmed NURBS.
- However they have partial .obj parser implemented to load objects. But they said, they support object hierarchies. If I got it correctly then it mean we can show sub components of regions and combinations.
July 11 2013
- Found a performance benchmark for different matrix libraries: http://stepheneb.github.io/webgl-matrix-benchmarks/matrix_benchmark.html.
- Still not clear which library is suitable.
- Talked to Sean on IRC about the code that's to be hooked in facetize.c. Have to move quickly.
July 12 2013
- Did some experiments with B-rep objects. My motive was to see how B-rep objects are represented in database file. First I made an implicit object and convert .g file to .asc then from .asc back to .g and it was successful. Then in new database file, made another object and made its brep object and converted file to .asc. In asc file I got message, "a Tcl output routine for this type of object has not yet been implemented" which means brep object was not described in .asc file. When this file converted back to g, all entities (one Implicit and one brep) were lost.
- Not much work done.
July 13 2013
- Reviewed glMatrix and WebGLU matrix library to see if they can satisfy our requirements.
July 14 2013
- Asked questions on webGL IRC about various matrix libraries.
- Prepared summary as told my Sean of his last email.
- After seeing reply, many things got cleared which I took other way earlier.
July 15 2013
Understanding the basics of various geometry representation forms to know more how they are used in graphics.
July 16 2013
Learned concepts behind Bezier curve and other basic things like control points, degree, basis function.
July 17 2013
Explored about NURBS and maths part behind its working. How control points and their weights played their part in making curve, purpose of knot vector. However, it need sufficient time to grasp all that completely. But now I have basic understanding to NURBS geometry.
July 18 2013
- Tried a basic NURBS specific example in OpenGL to see what basic functions are required to be ported to JavaSctipt(WebGLU).
- Looking into GLU's source code and looking for some other converter.
July 19 2013
- Found Emscripten: https://github.com/kripken/emscripten. From its description and demos, it looks promising and suitable for my work.
- Working on it.
July 20 2013
- Received mail from my mentor on mailing list having instructions about how to proceed further in project. So finally I will visualize polygonal OBJ files on browser, no need to use Emscripten.
- Started reading about how to read data from g file.
July 21 2013
July 22 2013
- Successfully retrieve name of database file, title, version, units from g file using pointer to db_i struct.
- Working out to retrieve names of entities from g file.
July 23 2013
- Made wire frame of layout.
- Prepared flow and implementation summary of project.
- Nothing found. Still working on same task of retrieving names of objects.
July 24 2013
- Making a small prototype of web models. Searched the Internet and found good examples of displaying OBJ files using ThreeJS.
- Basic scene is setup but getting problem with loading OBJ file.
- Tried to get solutions from IRC and Stack OverFlow, but not succeeded.
July 25 2013
- Made prototype of how BRL-CAD models will be interactively displayed on browser.
July 26 2013
- After little struggle, applied materials to models.
- But models are not rendering on Sean's browser in the same way as on mine. He is getting problem in viewing models after I assigned materials. Following are screenshots from my system:
July 27 2013
- I checked models on different browsers and systems. They are viewed differently on different machines but the browser version is same. Some are getting lines (tessellation lines) and some not.
- In the mean time, I successfully retrieve names of objects from database file.
July 28 2013
- I started moving towards making web interface. I found a ready made editor in ThreeJS source code.
- Reviewed the editor, used it to see what tasks similar to what I purposed in mock ups it can perform. It seems promising.
- Send email to BRL-CAD dev mailing list, expressing my interest in using this editor as base for project.
July 29 2013
No work done, due to some college related work.
July 30 2013
- Looked for different method of file uploading. I wanted to start with Drag n Drop support, but later I choose simpler method of browsing the files just to complete the overall flow. Made file upload feature. Drag n Drop support will be added at the time of actual interface implementation.
- Made and share future plans and ask for suggestions on mailing list.
July 31 2013
- Started with adding file upload option. I was planning to make this feature as drag n drop, but later I decided to first go with simple solutions.
- Added entity list display on browser.
August 01 2013
- Following mentor Rai's suggestions, added feature of generating OBJ files of first five entities as the file uploads.
August 02 2013
- I used PHP redirection to redirect to model display page.
- Now as the file upload finishes, model displayed on browser (although only first entity at the moment). So, at least the flow has been completed.
- Tested with all models that shipped with BRL-CAD source code. It worked perfectly with all files except those who have modeling errors. However, it look lot of time for files that have large number of entities (2000+) such as havoc.g but once OBJ files created model displayed successfully. I will recheck and discuss in detail on mailing list once I finished with setting up demo.
August 03 2013
- Added CSS to first page.
- Adjusted camera position and added additional directional light to light up the scene.
August 04 2013
- Changed the code so that in case if file already exists, it will directly display the models rather than uploading the same file and making OBJ files again.
- Removed unnecessary files and created repository on GitHub and pushed all the code.
August 05 2013
- Fixed problem of test.g file in the demo. Tested on different systems.
- Took break.
August 06 2013
- Took break.
August 07 2013
- Went to college for documents related work. Some documents are still left. Need to visit tomorrow. Too tired. :-(
August 08 2013
- Submitted the documents to college. Work finished.
- Looked into patch #183. Tried to reduce code of those two functions into one. But I suspect about the functionality and purpose of those two functions. Looks like a wrong step taken. Need to concentrate on other patch.
August 09 2013
- Searched for various similar implementations in brlcad src to see how to use hooks for bu_log output. Found in mged/cmd.c, util/plot-dm.c
- Studying how they are working.
August 10 2013
- With the help of example given in bu.h, I implemented error logging feature in journal command. It successfully logs output of bu_log to text file.
- Testing changes. With option that I added, on running journal command in MGED in classic mode (using -c option) it displays nothing. On quitting MGED it quits successfully. Looking into the problem.
August 11 2013
- On testing, found other problems that are introduced due to my changes. Although most of them are small and serious problem is only when BRL-CAD crashes on running "ls -A" command after reopening journal file in same MGED instance.
August 12 2013
- Called in the college. There was misunderstanding in the documents. Fixed it.
- I noticed that the problem of patch in classic mode is the same case when we redirect output / error to a text file using ">" and "2>". It redirects all output, and at that time nothing shows on screen.
August 13 2013
- Posted summary of efforts of this week to mentors.
- Decided and planned what to do and how to do next in the project.
- Took break.
August 14 2013
- As per my plan, I have to start with on-demand rendering option. Firstly, I sort out different aspects of this option on paper so that I could see the complete flow and what intermediate things I have to add to achieve this functionality.
August 15 2013
- Improved existing code as per HACKING file. However, need to inspect carefully before committing.
- Started working on on-demand rendering option as it makes an important part of project.
- Set layout according to mockups. Added divs.
August 16 2013
- Getting problem with onclick event handler. On clicking the link, function is not being called. Getting error that function not defined, but it is actually defined. Looking into it.
August 17 2013
- Still stuck at same problem.
- Took short break.
August 18 2013
- Finally, "onclick" problem solved. It was a scope problem.
- Added "View" and "Hide" links corresponding to each entity name. Working on implementing their corresponding backend functions.
August 19 2013
- Working on "on demand renderer". It has two parts: "On demand drawing" and "on demand deleting". Getting problem with entity display.
August 20 2013
- "On demand draw" part done. Actually, earlier I was taking it other way. But looking at some problem on Stack Overflow an idea came that I implemented and it worked. If I did what I planned earlier, no doubt it worked but it would consume more resources and might be less efficient.
- Now working on "on demand delete" part.
August 21 2013
- Still stuck at "on demand delete" problem. As such it is very small problem but till now unable to find any solution. Explored over the Internet and found one solution but that's not much efficient. Now I asked on Stack Overflow. Here is the link:
August 22 2013
- No useful response on Stack Overflow.
- Found one solution of my own but that's not much efficient. Actually in this solution, user can delete entities in reverse order as they are drawn. Before actually implementing it, looking for more efficient one.
August 23 2013
- Expanding that "inefficient" solution into useful one finally, "on demand delete" option done in a small standalone application. Now user can delete entities in random order. Next step is to implement it into actual application after testing. :)
- Solved few small issues that I got while testing. However, needs more intensive testing. Will share on mailing list once implemented into actual application.
- Not feeling well.
August 24 2013
- Solved various small issues that came up during implementation of "on demand delete option" into application. Now need to use AJAX to call "createOBJ" function (PHP) at a "onclick" event of "view" button.
- Fixed issues related to coding standards.
- Again not feeling well.
August 25 2013
- Working on AJAX request problem. Looking into the documentation. After this has been done, work of demand rendering facility will be finished.
August 26 2013
- Took break.
August 27 2013
- On demand entity draw / hide facility implemented.
- Now Next plans are to add sign-up / sign-in feature so that every user have his / her account and could access and manage uploaded files. Further I'll be adding attractive GUI for easy user experience. But before that, I would test whatever I did till now.
- I was successfully able to draw Goliath.c of goliath.g but found few issues.
August 28 2013
- While testing with BRL-CAD's default .g files, I noticed various points that needed to be considered to give user a better experience. I'll share them on mailing list.
- Now working on sign-up / sign-in feature.
August 29 2013
- Searched for sign-up modules on the Internet so that I could change / merge them into one that would be useful for this project.
- Found many, but need to combine them and reduce unnecessary features and code.
- Sign up feature is implemented, entry is being saved in database.
- Working on email verification.
August 30 2013
- Email verification is done.
- Created login page, landing page, and implemented sessions variables.
- Sign-up module is ready. Need testing.
August 31 2013
- Now the user is able to create account, login and logout successfully.
- Module tested successfully.
September 01 2013
- To make actual use of user accounts, I changed the code so that as soon as the user clicks on confirmation link (to activate account), the user directory (same as that of username filled while signing up) is created and a subdirectory "obj" (to store obj files) is also created.
September 02 2013
- Getting problem when user uploads a file. After upload, all entities of .g file erased. This was due to path problem. Actually the uploaded file was not being moved to desired directory and instead new empty .g file created in user directory having the same name as that of uploaded file. Anyway, this has been solved. Now the uploaded file is successfully saved in user's directory and with this sign-Up / sign-In work completed.
September 03 2013
- Testing the application after integrating with signup module. Identified possibilities where improvements can be done; will be added to TODO list.
- Added bootstrap CSS and custom CSS to improve look and feel.
September 04 2013
- Visited various sites similar to this application to get idea of perfect GUI. My main focus is to first work on the page where user see models and then change other pages accordingly as that page is main focus of this project. I think I need to add few more features to help user to view models in convenient way and since I noticed a lot of scope of this project so I need to discuss with developers about what to be added and what not within the GSoC period.
September 05 2013
- Took break.
September 06 2013
- Working on feature to enable the user to manage / access uploaded files, load old files from his dashboard.
September 07 2013
- Updated todo list on GitHub repository.
- Just finished with two new features: Now as the entity added to scene, it gets a random color. Now models look more colorful. At this moment colors being assigned to entities are random, in future this will be brought under control of user.
- Secondly, now models are drawn horizontally. Earlier, models drawn tilted (one side raised), were difficult to examine so fixing this just improved usability.