| 59 | | arguments.getApplicationUsage()->addCommandLineOption("",""); |
| 60 | | arguments.getApplicationUsage()->addCommandLineOption("",""); |
| 61 | | arguments.getApplicationUsage()->addCommandLineOption("",""); |
| 62 | | arguments.getApplicationUsage()->addCommandLineOption("",""); |
| 63 | | arguments.getApplicationUsage()->addCommandLineOption("",""); |
| 64 | | arguments.getApplicationUsage()->addCommandLineOption("",""); |
| 65 | | arguments.getApplicationUsage()->addCommandLineOption("",""); |
| 66 | | arguments.getApplicationUsage()->addCommandLineOption("",""); |
| 67 | | arguments.getApplicationUsage()->addCommandLineOption("",""); |
| 68 | | arguments.getApplicationUsage()->addCommandLineOption("",""); |
| | 61 | arguments.getApplicationUsage()->addCommandLineOption("--snow <density>","Set the snow with a density between 0 and 1.0"); |
| | 62 | arguments.getApplicationUsage()->addCommandLineOption("--rain <density>",""); |
| | 63 | arguments.getApplicationUsage()->addCommandLineOption("--particleSize <size>",""); |
| | 64 | arguments.getApplicationUsage()->addCommandLineOption("--particleColour <red> <green> <blue> <alpha>",""); |
| | 65 | arguments.getApplicationUsage()->addCommandLineOption("--wind <x> <y> <z>","Set the wind speed in model coordinates"); |
| | 66 | arguments.getApplicationUsage()->addCommandLineOption("--particleSpeed <float>","Set the particle speed"); |
| | 67 | arguments.getApplicationUsage()->addCommandLineOption("--nearTransition <distance>","Set the near transistion distance"); |
| | 68 | arguments.getApplicationUsage()->addCommandLineOption("--farTransition <distance>","Set the far transistion distance"); |
| | 69 | arguments.getApplicationUsage()->addCommandLineOption("--particleDensity <density>","Set the particle density"); |
| | 70 | arguments.getApplicationUsage()->addCommandLineOption("--cellSize <x> <y> <z>","Set the cell size in model coordinates"); |
| | 71 | arguments.getApplicationUsage()->addCommandLineOption("--fogDensity <density>","Set the fog density"); |
| | 72 | arguments.getApplicationUsage()->addCommandLineOption("--fogColour <red> <green> <blue> <alpha>","Set fog colour."); |
| | 73 | arguments.getApplicationUsage()->addCommandLineOption("-useFarLineSegments","Switch on the use of line segments"); |
| 173 | | // create the windows and run the threads. |
| 174 | | viewer.realize(); |
| 175 | | |
| 176 | | while( !viewer.done() ) |
| 177 | | { |
| 178 | | // wait for all cull and draw threads to complete. |
| 179 | | viewer.sync(); |
| 180 | | |
| 181 | | // update the scene by traversing it with the the update visitor which will |
| 182 | | // call all node update callbacks and animations. |
| 183 | | viewer.update(); |
| 184 | | |
| 185 | | // fire off the cull and draw traversals of the scene. |
| 186 | | viewer.frame(); |
| 187 | | |
| 188 | | } |
| 189 | | |
| 190 | | // wait for all cull and draw threads to complete. |
| 191 | | viewer.sync(); |
| 192 | | |
| 193 | | // run a clean up frame to delete all OpenGL objects. |
| 194 | | viewer.cleanup_frame(); |
| 195 | | |
| 196 | | // wait for all the clean up frame to complete. |
| 197 | | viewer.sync(); |
| 198 | | |
| 199 | | return 0; |
| | 162 | return viewer.run(); |