Editing User:AnkushKhandelwal/OpenGLRendering
From BRL-CAD
Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.
The edit can be undone.
Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 1: | Line 1: | ||
− | |||
'''Improve OpenGL Rendering''' | '''Improve OpenGL Rendering''' | ||
− | |||
− | |||
− | |||
Brief Description: The Objective of the project is to Re-factor and re-write the existing code of OpenSCAD preferably by implementing or using an existing rendering/scenegraph framework for cleaner rendering code. This newly developed infrastucture can be imported to softwares like GLES2 which opens up more possibilities like WebGL and native support for ARM Linux platforms that usually only provide GLES2 implementation. | Brief Description: The Objective of the project is to Re-factor and re-write the existing code of OpenSCAD preferably by implementing or using an existing rendering/scenegraph framework for cleaner rendering code. This newly developed infrastucture can be imported to softwares like GLES2 which opens up more possibilities like WebGL and native support for ARM Linux platforms that usually only provide GLES2 implementation. | ||
Line 11: | Line 7: | ||
*'''IRC username''': ank_95 | *'''IRC username''': ank_95 | ||
*'''Contact Number''': +918886330979 | *'''Contact Number''': +918886330979 | ||
− | |||
− | |||
==Background Information== | ==Background Information== | ||
− | * Pursuing Computer Science from IIIT Hyderabad, Andhra Pradesh, India. Currently in 2nd year | + | * Pursuing Computer Science from IIIT Hyderabad, Hyderabad, Andhra Pradesh, India. Currently in 2nd year. |
− | |||
* Worked in c, c++ and OpenGL 1/2/3. | * Worked in c, c++ and OpenGL 1/2/3. | ||
− | * My previous works in c++ | + | * My previous works in c++, OpenGL1, OpenGL2 : https://github.com/ankush1995/OpenGL |
* Interested in Graphics and front-end development. | * Interested in Graphics and front-end development. | ||
* I am a Linux user and want to step in the Open Source World. | * I am a Linux user and want to step in the Open Source World. | ||
* I am familiar with git. | * I am familiar with git. | ||
* Commit my work on git using github account(github.com/ankush1995). | * Commit my work on git using github account(github.com/ankush1995). | ||
− | |||
==Project Information== | ==Project Information== | ||
Line 46: | Line 38: | ||
We need to split out the openGL code from the polyset classes and all other classes and make a different class or data structure and it is used directly. In All it should be a seperate component which takes objects (for example , polyset) and renders it, in an effort to isolate the rendering from the rest of the software. The code of OpenSCAD is in openGL 2 and 1.1 + extentions and also we have users on openGL 2 and openGL 1.1 + extentions , so abstracting away OpenGL extensions and version differences is important. | We need to split out the openGL code from the polyset classes and all other classes and make a different class or data structure and it is used directly. In All it should be a seperate component which takes objects (for example , polyset) and renders it, in an effort to isolate the rendering from the rest of the software. The code of OpenSCAD is in openGL 2 and 1.1 + extentions and also we have users on openGL 2 and openGL 1.1 + extentions , so abstracting away OpenGL extensions and version differences is important. | ||
− | |||
− | |||
− | |||
− | |||
If we know exactly how much GL code is in a file , the next step would be to turn it into a separate component, i.e. a class or set of functions that take a polyset as parameter and renders it. This will help in making the main files of openSCAD, free from rendering, there will be a separate component for rendering. This class would then be responsible for converting polyset data into something more suitable for OpenGL.For example it does not make sense to render one single object in OpenGL ,it is not even supported in mordern OpenGL without enabling legacy compatibility. | If we know exactly how much GL code is in a file , the next step would be to turn it into a separate component, i.e. a class or set of functions that take a polyset as parameter and renders it. This will help in making the main files of openSCAD, free from rendering, there will be a separate component for rendering. This class would then be responsible for converting polyset data into something more suitable for OpenGL.For example it does not make sense to render one single object in OpenGL ,it is not even supported in mordern OpenGL without enabling legacy compatibility. | ||
− | |||
− | |||
− | |||
− | |||
− | |||
Then, in the future, when we use a real OpenGL framework, the renderer will most likely build a VBO using classes internal to that specific rendering framework all the VBO stuff would then be built without having to make any changes to the PolySet class. | Then, in the future, when we use a real OpenGL framework, the renderer will most likely build a VBO using classes internal to that specific rendering framework all the VBO stuff would then be built without having to make any changes to the PolySet class. | ||
If we can compile for example polyset without actually having OpenGL (e.g. on GLES2 box like Chromebook) in it then it will be a measure of success of code extraction. | If we can compile for example polyset without actually having OpenGL (e.g. on GLES2 box like Chromebook) in it then it will be a measure of success of code extraction. | ||
Line 96: | Line 79: | ||
'''Week 4(June 15)''' | '''Week 4(June 15)''' | ||
− | * Only the rendering part is separated, nothing else | + | * Only the rendering part is separated, nothing else. |
+ | * Excellent knowledge of c++ will be required. | ||
* The extracted OpenGL code is then written in a seperate component either a class or data structures. | * The extracted OpenGL code is then written in a seperate component either a class or data structures. | ||
* Linking the rendering code to the main infrastructure begins. | * Linking the rendering code to the main infrastructure begins. | ||
− | |||
− | |||
'''Week 5(June 22)''' | '''Week 5(June 22)''' | ||
− | * Making a seperate segment ( either a | + | * Making a seperate segment ( either a class or a data structure ). |
* These classes will be public, so that we can inherit the same in multiple files. | * These classes will be public, so that we can inherit the same in multiple files. | ||
* Extracting the OpenGL code from the various classes like polyset etc. | * Extracting the OpenGL code from the various classes like polyset etc. | ||
* Now the original files does not contain OpenGL code, all the OpenGL code is written in separate files. | * Now the original files does not contain OpenGL code, all the OpenGL code is written in separate files. | ||
− | * | + | * From where the OpenGL code is extracted, there just the objects are made, thats all, they are separated from the rendering part. |
− | |||
'''Week 6(June 29) ''' | '''Week 6(June 29) ''' | ||
Line 114: | Line 95: | ||
* This will help in decreasing code redundancy. Now the code will be more compact, distributed in various components. | * This will help in decreasing code redundancy. Now the code will be more compact, distributed in various components. | ||
* using same class or data structure for same objects which currently are written many times in different files. | * using same class or data structure for same objects which currently are written many times in different files. | ||
− | * Then we just have to make the same | + | * Then we just have to make the same object in both the files using one class. |
''' MID-term Evaluations''' | ''' MID-term Evaluations''' | ||
'''Week 7(July 6)''' | '''Week 7(July 6)''' | ||
+ | * Continuing with making a class/data structure to render the openGL code. | ||
* brushing up the code. | * brushing up the code. | ||
* Taking feedback about the new implementation. | * Taking feedback about the new implementation. |