hello I'm working on a project opengl. spot to do is to display a set of 3D objects in the form of successive views
(6 views for each object, for example). For extremely I happened to do the following:
- Run the program
- Enter the name of items
-wait for the visualization views and calculations required
-> Repeat these steps for the other items (almost 900 objects!)
So I thought to pass along the names of objects in tabular form in the program
* Unfortunately I could not do!
* I await your ideas for this?
the code used is long enough! it contains :
- ReadOffFile: read the object from the file and stores its data in a mesh structure
- Redraw: function that displays the object and make calculations
- Idle: triggers the display successively views
- Main: main function
- Other functions as usual init mainloop ...
Code :int main(int argc, char **argv) { // Initialize GLUT GLUTInit(&argc, argv); // Parse program arguments if (!ParseArgs(argc, argv)) exit(1); // Read file mesh = ReadOffFile(filenamme); if (!mesh) exit(1); // Run GLUT interface GLUTMainLoop(); system("pause"); // Return success return 0; }



Reply With Quote
