Show
Ignore:
Timestamp:
06/23/07 13:21:54 (7 years ago)
Author:
robert
Message:

Added setting of the Camera's projection matrix to fit the windowing aspect ratio.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • OpenSceneGraph/trunk/examples/osgviewerQT/osgviewerQT.cpp

    r6946 r7019  
    148148            getCamera()->setViewport(new osg::Viewport(0,0,width(),height())); 
    149149            getCamera()->setGraphicsContext(getGraphicsWindow()); 
     150            getCamera()->setProjectionMatrixAsPerspective(30.0f, static_cast<double>(width())/static_cast<double>(height()), 1.0f, 10000.0f); 
     151 
    150152            setThreadingModel(osgViewer::Viewer::SingleThreaded); 
    151153