Changeset 4488 for OpenSceneGraph/trunk/examples/osgcamera/osgcamera.cpp
- Timestamp:
- 08/31/05 22:39:05 (8 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
OpenSceneGraph/trunk/examples/osgcamera/osgcamera.cpp
r4486 r4488 14 14 15 15 #include <osgDB/ReadFile> 16 #include <osgDB/DynamicLibrary> 17 #include <osgDB/Registry> 16 18 17 19 #include <map> … … 74 76 } 75 77 76 osg:: ref_ptr<osg::CameraNode>_camera;78 osg::CameraNode* _camera; 77 79 osg::ref_ptr<osgUtil::SceneView> _sceneView; 78 80 }; … … 119 121 int main( int argc, char **argv ) 120 122 { 123 121 124 if (argc<2) 122 125 { … … 124 127 return 1; 125 128 } 129 130 // load the osgProducer library manually. 131 osg::ref_ptr<osgDB::DynamicLibrary> osgProducerLib = 132 osgDB::DynamicLibrary::loadLibrary(osgDB::Registry::instance()->createLibraryNameForNodeKit("osgProducer")); 133 126 134 127 135 // load the scene. … … 301 309 osg::Timer_t previous_tick = start_tick; 302 310 303 bool done = false; 311 bool done = false; 312 unsigned int maxNumFrames = 500; 304 313 305 314 // main loop - update scene graph, dispatch frame, wait for frame done. 306 while( !done )315 while( !done && frameNum<maxNumFrames) 307 316 { 308 317 … … 335 344 336 345 } 346 347 // delete the cameras, associated contexts and threads. 348 cameraList.clear(); 349 350 std::cout<<"Exiting application"<<std::endl; 351 337 352 return 0; 338 353 }
