Added support to slideshow3D for -s commandline option allow the size of
the display to be specified. Also implementaited some code for display position and speed info in osgProducer::Viewer, not fully implemented yet.
This commit is contained in:
@@ -97,9 +97,6 @@ class SG_EXPORT DisplaySettings : public osg::Referenced
|
||||
void setEyeSeparation(float eyeSeparation) { _eyeSeparation = eyeSeparation; }
|
||||
float getEyeSeparation() const { return _eyeSeparation; }
|
||||
|
||||
void setScreenDistance(float distance) { _screenDistance = distance; }
|
||||
float getScreenDistance() const { return _screenDistance; }
|
||||
|
||||
enum SplitStereoHorizontalEyeMapping
|
||||
{
|
||||
LEFT_EYE_LEFT_VIEWPORT,
|
||||
@@ -128,9 +125,16 @@ class SG_EXPORT DisplaySettings : public osg::Referenced
|
||||
bool getSplitStereoAutoAjustAspectRatio() const { return _splitStereoAutoAdjustAspectRatio; }
|
||||
|
||||
|
||||
void setScreenWidth(float width) { _screenWidth = width; }
|
||||
float getScreenWidth() const { return _screenWidth; }
|
||||
|
||||
void setScreenHeight(float height) { _screenHeight = height; }
|
||||
float getScreenHeight() const { return _screenHeight; }
|
||||
|
||||
void setScreenDistance(float distance) { _screenDistance = distance; }
|
||||
float getScreenDistance() const { return _screenDistance; }
|
||||
|
||||
|
||||
|
||||
void setDoubleBuffer(bool flag) { _doubleBuffer = flag; }
|
||||
bool getDoubleBuffer() const { return _doubleBuffer; }
|
||||
@@ -168,8 +172,9 @@ class SG_EXPORT DisplaySettings : public osg::Referenced
|
||||
bool _stereo;
|
||||
StereoMode _stereoMode;
|
||||
float _eyeSeparation;
|
||||
float _screenDistance;
|
||||
float _screenWidth;
|
||||
float _screenHeight;
|
||||
float _screenDistance;
|
||||
|
||||
SplitStereoHorizontalEyeMapping _splitStereoHorizontalEyeMapping;
|
||||
int _splitStereoHorizontalSeparation;
|
||||
|
||||
@@ -150,8 +150,14 @@ class OSGPRODUCER_EXPORT Viewer : public OsgCameraGroup, public osgGA::GUIAction
|
||||
const osg::AnimationPath* getAnimationPath() const { return _animationPath.get(); }
|
||||
|
||||
|
||||
const double* getPosition() const { return _position; }
|
||||
double getSpeed() const { return _speed; }
|
||||
osg::Quat getOrientation() const { return _orientation; }
|
||||
|
||||
|
||||
/** Get the keyboard and mouse usage of this viewer.*/
|
||||
virtual void getUsage(osg::ApplicationUsage& usage) const;
|
||||
|
||||
|
||||
protected :
|
||||
|
||||
@@ -166,11 +172,15 @@ class OSGPRODUCER_EXPORT Viewer : public OsgCameraGroup, public osgGA::GUIAction
|
||||
EventHandlerList _eventHandlerList;
|
||||
osg::ref_ptr<osgGA::KeySwitchMatrixManipulator> _keyswitchManipulator;
|
||||
|
||||
osg::ref_ptr<osg::NodeVisitor> _updateVisitor;
|
||||
osg::ref_ptr<osg::NodeVisitor> _updateVisitor;
|
||||
|
||||
bool _recordingAnimationPath;
|
||||
osg::ref_ptr<osg::AnimationPath> _animationPath;
|
||||
|
||||
// record the current position and orientation of the view.
|
||||
double _position[3];
|
||||
osg::Quat _orientation;
|
||||
double _speed;
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user