Changeset 25


Ignore:
Timestamp:
10/29/08 17:19:51 (4 years ago)
Author:
jschild
Message:

added an output field for the camera's projection matrix

Location:
trunk/avango-osg
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/avango-osg/include/avango/osg/viewer/Camera.h

    r1 r25  
    166166 
    167167        /** 
     168         * Outputs the projection matrix of the osg camera 
     169         */ 
     170        SFMatrix ProjectionMatrix; 
     171 
     172        /** 
    168173         * Get the wrapped ::osg::Camera. 
    169174         */ 
  • trunk/avango-osg/src/avango/osg/viewer/Camera.cpp

    r19 r25  
    138138  AV_FC_ADD_FIELD(MouseViewerTransform, ::osg::Matrix::identity()); 
    139139  AV_FC_ADD_FIELD(MouseNearTransform, ::osg::Matrix::identity()); 
     140  AV_FC_ADD_FIELD(ProjectionMatrix, ::osg::Matrix::identity()); 
    140141 
    141142  mOsgCamera->setReferenceFrame(::osg::Transform::ABSOLUTE_RF); 
     
    358359    if (MouseNearTransform.getValue() != mouse_near_trans) 
    359360      MouseNearTransform.setValue(mouse_near_trans); 
     361    if (ProjectionMatrix.getValue() != mOsgCamera->getProjectionMatrix()) 
     362      ProjectionMatrix.setValue(mOsgCamera->getProjectionMatrix()); 
    360363  } 
    361364} 
Note: See TracChangeset for help on using the changeset viewer.