VR-Forces 5.0.3 Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
DtOsgObserverObject.h
Go to the documentation of this file.
1 /*****************************************************************************
2  * Copyright (c) 2022 MAK Technologies, Inc.
3  * All rights reserved.
4  *****************************************************************************/
5 
9 
10 #pragma once
11 
12 #include <vrvOsg/vrvOsg.h>
14 
16 
18 
19 #include <osg/Matrixd>
20 #include <osg/Vec3d>
21 #include <osg/Vec3>
22 #include <osg/Node>
23 
24 #include <list>
25 #include <unordered_map>
26 
27 class DtTaitBryan;
28 
29 namespace osg
30 {
31  class Node;
32 }
33 
34 namespace makVrv
35 {
36  class DtChannel;
37  class DtOsgChannel;
38  class DtCoordinateConverter;
39  class DtSceneObject;
40  class DtTerrainPatchObject;
41  class DtAgentUpdateResolverInterface;
42  class DtIntersectorsContainer;
43  class DtCoordinateSystem;
44 
49  {
50 
51  public:
52 
54  {
55  TerrainResultNoData = 0,
57  TerrainResultComplete
58  };
59 
60  public:
61 
63  DtOsgObserverObject( DtDe& de, DtUniqueID id, const std::string& name="" );
64 
66  virtual ~DtOsgObserverObject();
67 
69  DtOsgObserverObject() = delete;
70 
73 
75  DtOsgObserverObject& operator=(const DtOsgObserverObject&) = delete;
76 
77  public:
78 
80  virtual void tick( double simTime );
81 
83  virtual void tickAttachment();
84 
87  virtual void setModelSet( int modelSet );
88 
90  virtual double altitude() const;
91 
92  virtual void setNameAndRegister( const std::string& name );
93 
99  virtual void setCameraPositionAndOrientation( const osg::Vec3d& position,
100  const osg::Quat& rotation );
101 
102  virtual void getCameraPositionAndOrientation( osg::Vec3d& position,
103  osg::Quat& rotation ) const;
104 
105 
107  static void matrixdToTaitBryan( const osg::Matrixd& mat, DtTaitBryan& tb, bool isWorld2D = false );
108  static double clampUnity( double x );
109 
110 
111  //
112  //
114  //
115  //
116 
118  virtual void startMoveObserverRight();
121  virtual void stopMoveObserverRight();
122  virtual void moveObserverRight( double meters );
123 
125  virtual void startMoveObserverForward();
128  virtual void stopMoveObserverForward();
129  virtual void moveObserverForward( double meters );
131 
133  virtual void startMoveObserverUp();
136  virtual void stopMoveObserverUp();
137  virtual void moveObserverUp( double meters );
139 
141  virtual void startMoveObserverLeft();
144  virtual void stopMoveObserverLeft();
145  virtual void moveObserverLeft( double meters );
147 
149  virtual void startMoveObserverBack();
152  virtual void stopMoveObserverBack();
153  virtual void moveObserverBack( double meters );
155 
157  virtual void startMoveObserverDown();
160  virtual void stopMoveObserverDown();
161  virtual void moveObserverDown( double meters );
163 
165  virtual void startMoveLevelObserverRight();
169  virtual void stopMoveLevelObserverRight();
170  virtual void moveLevelObserverRight( double meters );
172 
174  virtual void startMoveLevelObserverForward();
178  virtual void stopMoveLevelObserverForward();
179  virtual void moveLevelObserverForward( double meters );
181 
183  virtual void startMoveLevelObserverUp();
187  virtual void stopMoveLevelObserverUp();
188  virtual void moveLevelObserverUp( double meters );
190 
192  virtual void startMoveLevelObserverLeft();
196  virtual void stopMoveLevelObserverLeft();
197  virtual void moveLevelObserverLeft( double meters );
199 
201  virtual void startMoveLevelObserverBack();
205  virtual void stopMoveLevelObserverBack();
206  virtual void moveLevelObserverBack( double meters );
208 
210  virtual void startMoveLevelObserverDown();
213  virtual void stopMoveLevelObserverDown();
214  virtual void moveLevelObserverDown( double meters );
216 
218  virtual void startMoveAttachedRight();
221  virtual void stopMoveAttachedRight();
222  virtual void moveAttachedRight( double meters );
223 
225  virtual void startMoveAttachedForward();
228  virtual void stopMoveAttachedForward();
229  virtual void moveAttachedForward( double meters );
231 
233  virtual void startMoveAttachedUp();
236  virtual void stopMoveAttachedUp();
237  virtual void moveAttachedUp( double meters );
239 
241  virtual void startMoveAttachedLeft();
244  virtual void stopMoveAttachedLeft();
245  virtual void moveAttachedLeft( double meters );
247 
249  virtual void startMoveAttachedBack();
252  virtual void stopMoveAttachedBack();
253  virtual void moveAttachedBack( double meters );
255 
257  virtual void startMoveAttachedDown();
260  virtual void stopMoveAttachedDown();
261  virtual void moveAttachedDown( double meters );
263 
265  virtual void startMoveLevelAttachedRight();
269  virtual void stopMoveLevelAttachedRight();
270  virtual void moveLevelAttachedRight( double meters );
272 
274  virtual void startMoveLevelAttachedForward();
278  virtual void stopMoveLevelAttachedForward();
279  virtual void moveLevelAttachedForward( double meters );
281 
283  virtual void startMoveLevelAttachedUp();
287  virtual void stopMoveLevelAttachedUp();
288  virtual void moveLevelAttachedUp( double meters );
290 
292  virtual void startMoveLevelAttachedLeft();
296  virtual void stopMoveLevelAttachedLeft();
297  virtual void moveLevelAttachedLeft( double meters );
299 
301  virtual void startMoveLevelAttachedBack();
305  virtual void stopMoveLevelAttachedBack();
306  virtual void moveLevelAttachedBack( double meters );
308 
310  virtual void startMoveLevelAttachedDown();
313  virtual void stopMoveLevelAttachedDown();
314  virtual void moveLevelAttachedDown( double meters );
316 
318  virtual void startMoveAttachedContextRight();
321  virtual void stopMoveAttachedContextRight();
322  virtual void moveAttachedContextRight( double meters );
324 
326  virtual void startMoveAttachedContextForward();
329  virtual void stopMoveAttachedContextForward();
330  virtual void moveAttachedContextForward( double meters );
332 
334  virtual void startMoveAttachedContextUp();
337  virtual void stopMoveAttachedContextUp();
338  virtual void moveAttachedContextUp( double meters );
340 
342  virtual void startMoveAttachedContextLeft();
345  virtual void stopMoveAttachedContextLeft();
346  virtual void moveAttachedContextLeft( double meters );
348 
350  virtual void startMoveAttachedContextBack();
353  virtual void stopMoveAttachedContextBack();
354  virtual void moveAttachedContextBack( double meters );
356 
358  virtual void startMoveAttachedContextDown();
360  virtual void stopMoveAttachedContextDown();
361  virtual void moveAttachedContextDown( double meters );
363 
365  virtual void startYawLeft();
368  virtual void stopYawLeft();
369  virtual void rotateYawLeft(double rads);
371 
373  virtual void startYawRight();
377  virtual void stopYawRight();
378  virtual void rotateYawRight(double rads);
380 
382  virtual void startPitchUp();
385  virtual void stopPitchUp();
386  virtual void rotatePitchUp( double rads );
387  virtual void rotateFlashlightPitchUp( double rads );
389 
391  virtual void startPitchDown();
394  virtual void stopPitchDown();
395  virtual void rotatePitchDown( double rads );
396  virtual void rotateFlashlightPitchDown( double rads );
398 
400  virtual void startRollLeft();
403  virtual void stopRollLeft();
404  virtual void rollLeft(double rads);
406 
408  virtual void startRollRight();
411  virtual void stopRollRight();
412  virtual void rollRight(double rads);
414 
416  virtual void startLevelYawLeft();
419  virtual void stopLevelYawLeft();
421 
423  virtual void startLevelYawRight();
427  virtual void stopLevelYawRight();
429 
431  virtual void startLevelPitchUp();
434  virtual void stopLevelPitchUp();
435  virtual void rotateLevelPitchUp(double rads);
437 
439  virtual void startLevelPitchDown();
442  virtual void stopLevelPitchDown();
443  virtual void rotateLevelPitchDown(double rads);
445 
447  virtual void startLevelRollLeft();
450  virtual void stopLevelRollLeft();
451  virtual void rollLevelLeft(double rads);
453 
455  virtual void startLevelRollRight();
458  virtual void stopLevelRollRight();
459  virtual void rollLevelRight(double rads);
461 
462  virtual void rotateLevelYawLeft( double rads );
463  virtual void rotateLevelYawRight( double rads );
464  virtual void rotateFlashlightYawLeft( double rads );
465  virtual void rotateFlashlightYawRight( double rads );
466 
467  virtual void startLookLeft();
468  virtual void stopLookLeft();
469  virtual void lookLeft( double rads );
470 
471  virtual void startLookRight();
472  virtual void stopLookRight();
473  virtual void lookRight( double rads );
474 
475  virtual void startLookUp();
476  virtual void stopLookUp();
477  virtual void lookUp( double rads );
478 
479  virtual void startLookDown();
480  virtual void stopLookDown();
481  virtual void lookDown( double rads );
482 
483  virtual void startLookTiltRight();
484  virtual void stopLookTiltRight();
485  virtual void lookTiltRight( double rads );
486 
487  virtual void startLookTiltLeft();
488  virtual void stopLookTiltLeft();
489  virtual void lookTiltLeft( double rads );
490 
492  virtual void startOrbitingLeft();
495  virtual void stopOrbitingLeft();
496  virtual void orbitLeft( double rads );
498 
500  virtual void startOrbitingRight();
503  virtual void stopOrbitingRight();
504  virtual void orbitRight( double rads );
506 
508  virtual void startOrbitingUp();
511  virtual void stopOrbitingUp();
512  virtual void orbitUp( double rads );
514 
516  virtual void startOrbitingDown();
519  virtual void stopOrbitingDown();
520  virtual void orbitDown( double rads );
522 
524  virtual void setLocation( double x, double y, double z);
525 
529  virtual void setAttachedLocation( double x, double y, double z ) override;
530  virtual void setAttachedX( double x ) override;
531  virtual void setAttachedY( double y ) override;
532  virtual void setAttachedZ( double z ) override;
533  virtual void getAttachedPosition( double& x, double& y, double& z ) const override;
534 
536  virtual void setOrientation( double psi, double theta, double phi );
537 
539  virtual void setTopographicOrientation( double psi, double theta, double phi );
540 
542  virtual void setOrientation( double x, double y, double z, double w);
543 
545  virtual void setAttachedOrientation( double psi, double theta, double phi ) override;
546  virtual void setAttachedYaw(double psi) override;
547  virtual void setAttachedPitch(double theta) override;
548  virtual void setAttachedRoll(double phi) override;
549  virtual void getAttachedOrientation(double& psi, double& theta, double& phi) const override;
550 
552  virtual void setAttachedOrientation( double x, double y, double z,
553  double w);
554 
557  void setLocalModelScalingEnabled( bool enabled );
558 
561  void setLocalModelScalingAmount( float amount );
562 
565  virtual void jumpTo( double x, double y, double z );
566 
568  virtual void jumpTo( DtUniqueID elementID );
569 
570  virtual void orientTo( double x, double y, double z );
571 
573  virtual void dragTerrain( double lastX, double lastY, double lastZ,
574  double currX, double currY, double currZ );
575 
576  virtual void dragTerrain2( double myStartDragX, double myStartDragY,
577  double myStartDragZ, int deltaMouseX, int deltaMouseY );
578 
579  virtual void dragGravityUp( double windowUnits );
580  virtual void dragGravityDown( double windowUnits );
581  virtual void dragGravityLeft( double windowUnits );
582  virtual void dragGravityRight( double windowUnits );
583  virtual void scrollObserverForward( int wheelUnits );
584  virtual void scrollObserverBack( int wheelUnits );
585  virtual void scrollLevelObserverForward( int wheelUnits );
586  virtual void scrollLevelObserverBack( int wheelUnits );
587 
588  virtual void scrollFlashlightWider( int wheelUnits );
589  virtual void scrollFlashlightNarrower( int wheelUnits );
590 
592  virtual float flashlightAngle();
593 
594  //{@
596  virtual void startIncreasingViewResolution();
597  virtual void stopIncreasingViewResolution();
598  virtual void increaseViewResolution();
599 
600  virtual void startDecreasingViewResolution();
601  virtual void stopDecreasingViewResolution();
602  virtual void decreaseViewResolution();
603 
604  // Sets the view resolution in meters per pixel.
605  virtual void setViewResolution( double resolution);
606 
607  // Get the current view resolution.
608  virtual double viewResolution() const;
609 
615  virtual void setCurrentViewMagnification( double mag );
616 
618  virtual double currentViewMagnification() const;
619 
621 
622  //
624  //
625 
627  virtual void setOrbitSpeed( double speed );
628 
630  virtual void setLinearSpeed( double speed );
631 
633  virtual void setRotationSpeed( double speed );
634 
636  virtual void setMinLinearSpeed( double minSpeed );
637 
639  virtual void setMaxLinearSpeed( double maxSpeed );
640 
642  virtual void setLinearScaledSpeedGain( double gain );
643 
649  virtual void gotoTerrainCenter( DtUniqueID terrainPatch, bool retry );
650 
652  virtual void resetAttachment();
653 
654  virtual void resetOrientation();
655 
657  virtual void resetCamera();
658  virtual void level();
659 
660  virtual void stopAll();
661 
662  virtual void attachToObjects( const std::vector<DtUniqueID>& elementIds );
663  virtual void setSecondaryAttachment( const std::vector<DtUniqueID>& elementIds );
664  virtual void setLocationTrackAttachment( const osg::Vec3d& location );
665  virtual void setLocationTrackAttachment( double x, double y, double z );
666 
667  virtual void attachToPart( int partId);
668  virtual void detach();
669  virtual void setAttachType( DtObserverObject::AttachType type );
670  virtual void setHideModelOnAttach( bool hide );
671 
674  virtual void setUsesBoundingVolumeForAttachedOffsets(bool useBoundingVolume);
675 
678  virtual bool usesBoundingVolumeForAttachedOffsets() const;
679 
683  virtual void setAttachmentHas3DCockpit( bool cockpit );
684 
685  virtual void scaleCurrentAttachments( bool scaled );
686  virtual void setOrientToTargetConstraint( bool orient );
687  virtual void setOrbiting( bool orbit );
688  virtual void setOrientCameraToTargetConstraint( bool orient );
689 
690  virtual void setConstrainToTerrain( bool trueFalse );
691  virtual void setConstrainToCenter( bool trueFalse );
692 
695  virtual void suppressConstrainToTerrain( bool trueFalse );
696 
697  virtual void setSpeedScaling( bool trueFalse );
698 
700  virtual void setSpeedScaledSpeed( double speed );
701 
703  virtual void getLocation(double &x, double &y, double& z) const;
705  virtual void getObserverPosition(double &x, double &y, double& z) const;
706  virtual void getEffectiveLocation(double &x, double &y, double& z) const;
708 
710  virtual void getObserverCameraPosition(double& x, double& y, double& z) const;
711 
713  virtual void getOrientation( double& psi, double& theta, double& phi ) const;
714 
717  virtual void getObserverCameraOrientation(double& psi, double& theta, double& phi, bool includeShake) const;
718 
720  virtual void getTopographicOrientation( double& psi, double& theta, double& phi ) const;
721 
722  virtual void getOrientation( double& x, double& y, double& z, double& w ) const;
723 
724  virtual void getFlashlightOrientation( double& x, double& y, double& z, double& w ) const;
725 
728  virtual void getObserverPlatformFront(double& x, double& y, double& z) const;
729 
732  virtual void getObserverPlatformUp(double& x, double& y, double& z) const;
733 
736  virtual void getObserverPlatformRight(double& x, double& y, double& z) const;
737 
740  virtual void getObserverCameraFront(double& x, double& y, double& z, bool includeShake) const;
741 
743  virtual void getObserverCameraUp(double& x, double& y, double& z, bool includeShake) const;
744 
746  virtual void getObserverCameraRight(double& x, double& y, double& z, bool includeShake) const;
747 
748  virtual void getCameraUp(double& x, double& y, double& z);
749 
750  virtual void getCameraFront(double& x, double& y, double& z);
751 
752  virtual void getCameraRight(double& x, double& y, double& z);
753 
755  virtual void setCameraShakeRotation(double x, double y, double z, double w);
756 
758  virtual void getCameraShakeRotation(double& x, double& y, double& z, double& w);;
759 
762 // virtual double calculate2DAltitude();
763 
764 
767  virtual double heightAboveTerrainFromCurrentZoom(double magnification = 1.) const;
768 
772  virtual double altitudeFromCurrentZoom(double magnification=1.) const;
773 
776  virtual double zoomFromHeightAboveTerrain(double hat, double magnification=1) const;
777 
780  virtual double zoomFromAltitude(double altitude, double magnification=1.) const;
781 
782 
786  virtual double zoomFromCurrentAltitude() const;
787 
790  virtual double topographicHeading() const;
791 
793  virtual void getLinearVelocity(double &x, double &y, double &z) const;
794 
796  virtual void getRotationalVelocity( double& x, double& y, double& z) const;
797 
801  virtual void setModeSetting( int setting, bool value );
802 
805  virtual void setNorthType(DtObserverObject::NorthType northType);
806 
808  virtual std::vector<DtUniqueID> currentAttachments() const;
809 
812 
813  virtual const osg::Vec3d& locationTrackAttachmentVec3d() const;
814  virtual void getLocationTrackAttachment( double& x, double& y, double& z ) const;
816 
820  virtual DtObserverObject::AttachType attachType3D() const;
821 
825  virtual DtObserverObject::AttachType attachType2D() const;
826 
828  virtual bool attachedObjectHidden() const;
829 
833  virtual bool attachmentHas3DCockpit() const;
834 
837  virtual osg::Vec3d attachedOffsetVector() const;
838 
843  virtual double attachedNearClipOffset() const;
844 
846  virtual double heightAboveTerrain() const;
847 
849  virtual double heightOfTerrain() const;
850 
852  virtual const DtIntersectorsContainer* intersectorsContainer(void) const;
853 
855  virtual DtIntersectorsContainer* intersectorsContainer(void);
856 
857  protected:
858 
860  virtual bool shouldOrientToGlobeCenter();
861 
863  virtual void adjustToGlobeCurvature();
864 
866  virtual bool shouldRotateGlobe();
867 
868  virtual void calcObserverWorldVectors();
869  virtual const osg::Vec3d& observerWorldUp() const;
870  virtual const osg::Vec3d& observerWorldNorth() const;
871  virtual const osg::Vec3d& observerWorldEast() const;
872 
873  virtual const osg::Vec3d& attachedWorldUp() const;
874 
875  virtual osg::Vec3d& observerUp();
876  virtual osg::Vec3d& observerFront();
877  virtual osg::Vec3d& observerRight();
878  virtual void observerBasis(osg::Vec3d& up, osg::Vec3d& front, osg::Vec3d& right);
879 
880  virtual osg::Vec3d& attachedUp();
881  virtual osg::Vec3d& attachedFront();
882  virtual osg::Vec3d& attachedRight();
883 
884  virtual osg::Vec3d& attachedOffsetUp();
885  virtual osg::Vec3d& attachedOffsetFront();
886  virtual osg::Vec3d& attachedOffsetRight();
887 
889  virtual osg::Vec3d& levelAttachedUp();
890  virtual osg::Vec3d& levelAttachedFront();
891  virtual osg::Vec3d& levelAttachedRight();
892 
894  virtual osg::Vec3d& levelObserverMimicUp();
895  virtual osg::Vec3d& levelObserverMimicFront();
896  virtual osg::Vec3d& levelObserverMimicRight();
897 
898  virtual osg::Vec3d& cameraUp();
899  virtual osg::Vec3d& cameraFront();
900  virtual osg::Vec3d& cameraRight();
901 
902  virtual osg::Vec3d& levelObserverUp();
903  virtual osg::Vec3d& levelObserverFront();
904  virtual osg::Vec3d& levelObserverRight();
905 
906  virtual void advanceOrbitLeft( double rads );
907  virtual void advanceOrbitRight( double rads );
908  virtual void advanceOrbitUp( double rads );
909  virtual void advanceOrbitDown( double rads );
910 
911  virtual void makeLevelObserverMatrix();
912 
914  virtual void calculateLevelAttachedRotation();
915 
917  virtual void makeLevelObserverMimicMatrix();
918 
922  virtual osg::Vec3d calcWorldPositionChange();
923 
924  virtual osg::Vec3d calcMimicPositionChange();
925 
926  virtual osg::Vec3d calcAttachedPosition(const osg::Quat& attInverse, const osg::Vec3d& attachedAdvance);
927  virtual osg::Vec3d calcAttachedAdvance(const osg::Quat& tetherTrackInverse);
928 
929  virtual osg::Vec3d calcFollowPositionChange();
930  virtual osg::Vec3d calcSpaceFollowPositionChange();
931  virtual osg::Vec3d calcTetherPositionChange();
932  virtual osg::Vec3d calcTetherTrackPositionChange();
933 
934  virtual osg::Vec3d calcTrackPositionChange();
935  virtual osg::Quat calcTetherTrackRotation();
936 
937  virtual osg::Quat calcFlashlightOrientationChange();
938  virtual osg::Quat calcWorldOrientationChange();
939  virtual osg::Quat calcTetherOrientationChange();
940  virtual osg::Quat calcMimicOrientationChange();
941  virtual osg::Quat calcFollowOrientationChange();
942 
943  virtual void setCurrentAttachmentsVisibility( bool visible );
944 
951 
954  virtual void orientTo( const osg::Vec3d& target );
955 
957  virtual void orientCameraTo( const osg::Vec3d& target );
958 
959  virtual TerrainResult getTerrainCenter( const DtUniqueID& patchID, osg::Vec3d& center );
960 
961  virtual DtCoordinateConverter& coordinateConverter();
962  virtual const DtCoordinateConverter& coordinateConverter() const;
963 
964  virtual void initializeAttachment();
965 
966  virtual const osg::Vec3d& scalingIntersection() const;
967  virtual void getViewIntersection();
968 
970  virtual double linearSpeed();
971 
973  virtual double speedScalingGain() const;
974 
975  virtual void calcTerrainConstraint(const osg::Vec3d& prev );
976 
982  virtual bool updateAttachPositionAndOrientation();
983 
984  virtual bool getSecondaryAttachPosition( osg::Vec3d& position );
985 
986  virtual void getObserverOffsetVector( double& x, double& y, double& z ) const;
987  virtual void setObserverOffsetVector( double x, double y, double z );
988 
991 
992  virtual void getCameraFromParentOffsetVector( double& x, double& y, double& z ) const;
993  virtual void getCameraFromParentRotationOffset( double& x, double& y, double& z, double& w ) const;
995 
996  virtual void getAttachedRotationOffset( double& x, double& y, double& z, double& w ) const;
997  virtual void setAttachedRotationOffset( double x, double y, double z,
998  double w );
999 
1000  virtual void getBoundingVolume( DtSceneObject& sceneObject,
1001  osg::Vec3& bvolExtents, osg::Vec3d& bvolCenter );
1002 
1003  virtual void getBoundingVolume( DtTerrainPatchObject& patchObject,
1004  osg::Vec3& bvolExtents, osg::Vec3d& bvolCenter );
1005 
1006  virtual void setLocation( const osg::Vec3d& location, bool suppress=true );
1007 
1008  virtual bool isMoving() const;
1009  virtual bool isRotating() const;
1010 
1011  virtual double computeNearClipDistance( DtSceneObject* sceneObject );
1012  virtual float computeLocalModelScalingAmount( DtSceneObject* sceneObject );
1013 
1014  virtual void calcScaledSpeed();
1015  virtual bool getTerrainOrPropIntersection( const osg::Vec3d& startPos,
1016  const osg::Vec3d& endPos, osg::Vec3d& result, const osg::Node::NodeMask mask = ~DtOsgNodeFlags::FlagSupportOff) const;
1017 
1019  virtual DtSceneObject* findSceneObjectFromElement(const DtElementID& id);
1020 
1022  virtual DtTerrainPatchObject* findTerrainPatchObjectFromElement( DtElementID id );
1023  virtual DtOsgObserverObject* findObserverObjectFromElement( DtElementID id );
1024 
1025  virtual void getPositionAndOrientation( DtSceneObject& sceneObject, osg::Vec3d& position,
1026  osg::Vec3d& orientToPosition, osg::Quat& orientation );
1027 
1028  virtual void getPositionAndOrientation( DtTerrainPatchObject& patchObject, osg::Vec3d& position,
1029  osg::Vec3d& orientToPosition, osg::Quat& orientation );
1030 
1031  virtual void getPositionAndOrientation( DtOsgObserverObject& observerObject, osg::Vec3d& position,
1032  osg::Vec3d& orientToPosition, osg::Quat& orientation );
1033 
1035  virtual void getPositionFromSceneObject( DtSceneObject& sceneObject, osg::Vec3d& position ) const;
1036 
1038  virtual void getPositionFromObserverObject( DtOsgObserverObject& observerObject, osg::Vec3d& position ) const;
1039 
1042  virtual bool getPartPositionOriFromSceneObject( DtSceneObject& sceneObject,
1043  int partId, osg::Vec3d& position, osg::Quat& ori ) const;
1044 
1047  virtual void force2D();
1048 
1050  virtual void dimensionChanged( bool is2D );
1051  virtual void setIs2D( bool is2D );
1052 
1054  virtual double calculate3DAltitude() const;
1055 
1057  virtual void calculateAltitude();
1058 
1059  // Sends the location of the observer on the master to all others; only used
1060  // if different
1061  virtual void synchronizeLocation( double x, double y, double z );
1062 
1063  // Sends the orientation of the observer on the master to all others; only used
1064  // if different
1065  virtual void synchronizeOrientation( double x, double y, double z, double w );
1066 
1082  virtual void calcHeightAboveTerrain(bool force=false);
1083 
1085  std::list<DtChannel*> findChannels();
1088  std::list<const DtChannel*> findChannels() const;
1090 
1099  virtual double frustumPixelHeight() const;
1100 
1102  virtual void slot_coordinateSystemChanged();
1103 
1105  virtual void cache3DOffsetAndRotation();
1106 
1108  virtual void restoreAttachOffsetsFrom3DCache();
1109 
1110 
1113  virtual void slot_dateChanged();
1114 
1117  virtual bool getAttachedToBoundingVolume(DtSceneObject* const sceneObject, osg::Vec3d& boundingVolumeCenter, osg::Vec3& boundingVolumeExtents,
1118  double& maxOffset, double& maxExtent);
1119 
1122  virtual bool setupAttachOffsetsAfterReset(DtSceneObject* const sceneObject, osg::Vec3d boundingVolumeCenter, osg::Vec3 boundingVolumeExtents,
1123  double maxOffset, double maxExtent);
1124 
1128  virtual void setupAttachOffsets(double maxExtent);
1129 
1132  virtual void reinitializeAfterBoundingVolumeChange();
1133 
1136  virtual void resetAfterBoundingVolumeChange();
1137 
1138  protected:
1139 
1140  static const double theObserverBoundingSphere;
1142 
1143  static const double theMaxTerrainRetryTime;
1144 
1145  // below this altitude, ignore myConstrainToCenter
1146  static const double theCenterConstrainHeight;
1147 
1148  // Zoom won't get any smaller than this
1149  static const double theMinViewResolution;
1150 
1151  // Zoom won't get any larger than this
1152  static const double theMaxViewResolution;
1153 
1154 
1155  protected:
1156 
1158 
1159  std::vector<DtUniqueID> myCurrentAttachments;
1160  std::vector<DtUniqueID> mySecondaryAttachments;
1162 
1166 
1169 
1170  //
1172  //
1181 
1184 
1187 
1190 
1193 
1196 
1198 
1200 
1202  osg::Vec3d myDragMove;
1203 
1205 
1206  osg::Vec3d myOrbitAdvance;
1207 
1213 
1216 
1219  osg::Quat myMasterRotation;
1220 
1223 
1226 
1231 
1234 
1237 
1242 
1248 
1249  //bool myGlobeObserverMode;
1251 
1254 
1256  {
1257  public:
1258 
1260  {
1261  Stopped = 0,
1262  Forward = 1,
1263  Backward = 2,
1264  Left = 4,
1265  Right = 8,
1266  Up = 16,
1267  Down = 32
1268  };
1269 
1271  : myState(Stopped)
1272  {
1273  }
1274 
1276  inline void applyMovement(double linearDistance)
1277  {
1278  if(moving(Right)) myAdvance[0] += linearDistance;
1279  if(moving(Left)) myAdvance[0] -= linearDistance;
1280  if(moving(Forward)) myAdvance[1] += linearDistance;
1281  if(moving(Backward)) myAdvance[1] -= linearDistance;
1282  if(moving(Up)) myAdvance[2] += linearDistance;
1283  if(moving(Down)) myAdvance[2] -= linearDistance;
1284  }
1285 
1287  inline const osg::Vec3d& advance() const
1288  {
1289  return myAdvance;
1290  }
1291 
1292  inline void stop()
1293  {
1294  myState = Stopped;
1295  myAdvance.set(0.0,0.0,0.0);
1296  myEuler.set(0.0,0.0,0.0);
1297  }
1298 
1299  inline void clearAdvance()
1300  {
1301  myAdvance.set(0.0,0.0,0.0);
1302  }
1303 
1304  inline bool stopped()
1305  {
1306  return myState == Stopped;
1307  }
1308 
1309  inline bool moving() const
1310  {
1311  return myState != Stopped;
1312  }
1313 
1314  inline bool moving(Direction d) const
1315  {
1316  return (myState & d) != 0;
1317  }
1318 
1319  inline void setMoving(Direction d, bool moving)
1320  {
1321  myState = moving ? myState | d : myState & ~d;
1322  }
1323 
1324  enum Angle
1325  {
1326  YawLeft = 1,
1327  YawRight = 2,
1328  PitchUp = 4,
1329  PitchDown = 8,
1330  RollLeft = 16,
1331  RollRight = 32
1332  };
1333 
1334  inline void applyRotation(double angle)
1335  {
1336  if(rotating(YawRight)) myEuler[0] -= angle;
1337  if(rotating(YawLeft)) myEuler[0] += angle;
1338  if(rotating(PitchUp)) myEuler[1] += angle;
1339  if(rotating(PitchDown)) myEuler[1] -= angle;
1340  if(rotating(RollRight)) myEuler[2] += angle;
1341  if(rotating(RollLeft)) myEuler[2] -= angle;
1342  }
1343 
1344  inline const osg::Vec3d& euler() const
1345  {
1346  return myEuler;
1347  }
1348 
1349  inline osg::Vec3d& euler()
1350  {
1351  return myEuler;
1352  }
1353 
1354  inline void level()
1355  {
1356  myEuler.set(0.0,0.0,0.0);
1357  }
1358 
1359  inline bool rotating() const
1360  {
1361  return myState != Stopped;
1362  }
1363 
1364  inline bool rotating( Angle d ) const
1365  {
1366  return (myState & d) != 0;
1367  }
1368 
1369  inline void setRotating( Angle d, bool rotating )
1370  {
1371  myState = rotating ? myState | d : myState & ~d;
1372  }
1373 
1374  protected:
1375 
1379  osg::Vec3d myAdvance;
1380  osg::Vec3d myEuler;
1381 
1382  unsigned char myState;
1383  };
1384 
1389 
1394 
1396 
1401 
1405 
1411 
1415 
1416  //
1425 
1429 
1433 
1435  osg::Vec3d myCameraOffset;
1437  osg::Quat myCameraRotation;
1438 
1439  osg::Vec3d myObserverWorldUp;
1442 
1443  osg::Vec3d myAttachedWorldUp;
1446 
1447  osg::Vec3d myObserverUp;
1448  osg::Vec3d myObserverFront;
1449  osg::Vec3d myObserverRight;
1450 
1451  osg::Vec3d myLevelObserverUp;
1454 
1455  osg::Vec3d myAttachedUp;
1456  osg::Vec3d myAttachedFront;
1457  osg::Vec3d myAttachedRight;
1458 
1459  osg::Vec3d myLevelAttachedUp;
1462 
1466 
1470 
1471  osg::Vec3d myCameraUp;
1472  osg::Vec3d myCameraFront;
1473  osg::Vec3d myCameraRight;
1474 
1476 
1481 
1483 
1486 
1489 
1498  // force an orientation reset AFTER the next time the observer position is updated
1499  // Needed when making large attach jumps
1501 
1509 
1511 
1513  osg::Vec3d myViewIntersect;
1514 
1516  mutable osg::Vec3d myMutableDownIntersect;
1517 
1518  osg::Vec3d myAttachPosition;
1519 
1522 
1526 
1527  double myAltitude;
1528 
1533 
1537 
1538  typedef std::unordered_map<DtElementID, bool> ElementVisibilityMap;
1540 
1541  // Paged terrain initialization
1549 
1550  // Used for speed scaling, this is the same as myHeightAboveTerrain
1551  // when unattached, but the distance from the attached entity when
1552  // attached
1554 
1555  // curvature adjustment
1559 
1560  osg::Quat myCameraShakeRot;
1561 
1563 
1564  DtIntersectorsContainer* myIntersectors = nullptr;
1565 
1567 
1570  DtCoordinateSystem* myCoordinateSystem = nullptr;
1571  };
1572 
1573 }
osg::Quat myCameraRotation
This is the camera (wrt the observer) as a quaternion.
Definition: DtOsgObserverObject.h:1437
osg::Vec3d myDragMove
Change in world position due to drag.
Definition: DtOsgObserverObject.h:1202
osg::Vec3d myMutableDownIntersect
Definition: DtOsgObserverObject.h:1516
Definition: DtOsgObserverObject.h:56
bool myHaveViewIntersect
Definition: DtOsgObserverObject.h:1512
void setRotating(Angle d, bool rotating)
Definition: DtOsgObserverObject.h:1369
ElementVisibilityMap myPendingVisibilityState
Definition: DtOsgObserverObject.h:1539
bool myAttachmentHas3DCockpit
Definition: DtOsgObserverObject.h:1478
osg::Vec3d myLevelObserverMimicUp
Definition: DtOsgObserverObject.h:1463
osg::Vec3d myAttachedWorldEast
Definition: DtOsgObserverObject.h:1445
bool myHave3DOffsetCache
Definition: DtOsgObserverObject.h:1243
int myOrientToTargetConstraint
This is an int rather than a bool because we increment/decrement it, much like a reference pointer...
Definition: DtOsgObserverObject.h:1494
osg::Vec3d myObserverUp
Definition: DtOsgObserverObject.h:1447
double myHeightOfTerrain
Definition: DtOsgObserverObject.h:1548
std::vector< DtUniqueID > myCurrentAttachments
Definition: DtOsgObserverObject.h:1159
double myStartGotoTerrainCenterTime
Definition: DtOsgObserverObject.h:1544
static const unsigned int FlagSupportOff
Is this node part of support (whether or not other scene objects can ground clamp to this model) ...
Definition: DtOsgNodeTraversalFlags.h:22
osg::Quat myLevelAttachedRotation
Definition: DtOsgObserverObject.h:1233
osg::Vec3d myAttachedOffsetUp
Definition: DtOsgObserverObject.h:1467
osg::Vec3d myAttachedOffsetRight
Definition: DtOsgObserverObject.h:1469
osg::Vec3d myOrbitAdvance
Definition: DtOsgObserverObject.h:1206
DtCoordinateConverter is the base class for &#39;local (cig) to geocentric&#39; converters.
Definition: DtCoordinateConverter.h:25
osg::Vec3d myCameraRight
Definition: DtOsgObserverObject.h:1473
osg::Vec3d myCameraUp
Definition: DtOsgObserverObject.h:1471
double myHeightAboveTerrain
Definition: DtOsgObserverObject.h:1547
double myMaxLinearSpeed
Need just these, for terrain scaling.
Definition: DtOsgObserverObject.h:1407
#define DT_DLL_VRVOSG
Definition: vrvOsg.h:23
double myLinearSpeed
Definition: DtOsgObserverObject.h:1403
This form is used for doing level (&#39;flying carpet&#39;) style movements.
Definition: DtOsgObserverObject.h:1255
osg::Vec3d myLevelAttachedFront
Definition: DtOsgObserverObject.h:1460
DT_DLL_VRVCORE DtTaitBryan level(const DtCoordinateSystem &cs, const DtVector &localOrigin, double topoHeading)
Returns a level orientation with the topographic heading.
bool myOrbitingLeft
Definition: DtOsgObserverObject.h:1397
osg::Vec3d myObserverPosition
Change in observer position this frame.
Definition: DtOsgObserverObject.h:1192
Contains makVrv:DtOsgNodeTraversalFlags class.
Utility class that contains intersectors for all model sets in the system (3d, xr, 2d) Use an object of this class when all models sets can be possibly needed. When you know which model set you need, you can just use the DtIntersectorCreator to create an intersector for a model set Models sets corresponding to 3d, xr and 2d are created by default (these correspond to values of 0, 1 and 5) Additional model sets can be registered with DtIntersectorsContainer::registerModelSet.
Definition: DtIntersectorsContainer.h:36
MotionState myFlashlightRotatingState
Definition: DtOsgObserverObject.h:1395
osg::Vec3d myLocationAttachPoint
Definition: DtOsgObserverObject.h:1562
osg::Vec3d my2DTo3DCachedObserverOffsetVector
Definition: DtOsgObserverObject.h:1239
osg::Vec3d myLevelAttachedPosition
Definition: DtOsgObserverObject.h:1199
double mySceneCenterOffsetX
Definition: DtOsgObserverObject.h:1412
void level()
Definition: DtOsgObserverObject.h:1354
bool mySpeedScaling
Definition: DtOsgObserverObject.h:1479
bool myViewResolutionDecreasingState
Definition: DtOsgObserverObject.h:1531
osg::Vec3d myLevelObserverFront
Definition: DtOsgObserverObject.h:1452
double myViewResolution
Definition: DtOsgObserverObject.h:1532
bool myLookingUp
Definition: DtOsgObserverObject.h:1421
osg::Vec3d myAttachedOffsetFront
Definition: DtOsgObserverObject.h:1468
osg::Matrixd myLevelObserverRotationMatrix
Definition: DtOsgObserverObject.h:1236
bool myOrbitingUp
Definition: DtOsgObserverObject.h:1399
static const double theCenterConstrainHeight
Definition: DtOsgObserverObject.h:1146
void applyMovement(double linearDistance)
Update the advance based upon the movement.
Definition: DtOsgObserverObject.h:1276
std::unordered_map< DtElementID, bool > ElementVisibilityMap
Definition: DtOsgObserverObject.h:1538
TerrainResult
Definition: DtOsgObserverObject.h:53
bool myOrbitingDown
Definition: DtOsgObserverObject.h:1400
bool myInternalSuppressConstrainToTerrain
suppress when jumping...
Definition: DtOsgObserverObject.h:1485
osg::Vec3d myObserverWorldUp
Definition: DtOsgObserverObject.h:1439
bool rotating(Angle d) const
Definition: DtOsgObserverObject.h:1364
osg::Vec3d myAttachedWorldNorth
Definition: DtOsgObserverObject.h:1444
osg::Vec3d myLevelObserverRight
Definition: DtOsgObserverObject.h:1453
bool myHaveTerrainPivot
Definition: DtOsgObserverObject.h:1510
const osg::Vec3d & advance() const
Get the current movement advance.
Definition: DtOsgObserverObject.h:1287
osg::Vec3d myAttachedFront
Definition: DtOsgObserverObject.h:1456
osg::Vec3d myLevelAttachedUp
Definition: DtOsgObserverObject.h:1459
osg::Quat myAttachedRotationOffset
My Attached rotation offset.
Definition: DtOsgObserverObject.h:1215
osg::Quat myPreviousAttachedObserverRotation
This is here so we can be in tether attach mode, detach, then attach to another entity and have a rea...
Definition: DtOsgObserverObject.h:1230
double mySpeedScaleHeightEquivalent
Definition: DtOsgObserverObject.h:1553
MotionState myAbsoluteLevelRotatingState
Definition: DtOsgObserverObject.h:1393
osg::Quat my2DTo3DCachedObserverRotationOffset
Definition: DtOsgObserverObject.h:1241
unsigned char myState
Definition: DtOsgObserverObject.h:1382
bool myLookingTiltLeft
Definition: DtOsgObserverObject.h:1424
DtSignalConnectionManager myConnections
Definition: DtOsgObserverObject.h:1566
double myLinearScaledSpeedGain
Definition: DtOsgObserverObject.h:1409
osg::Vec3d myObserverPositionVector
— Observer
Definition: DtOsgObserverObject.h:1174
bool myLookingLeft
Definition: DtOsgObserverObject.h:1420
osg::Vec3d myPreviousOffsetVector
Definition: DtOsgObserverObject.h:1525
bool myGotoTerrainCenterPending
Definition: DtOsgObserverObject.h:1542
A DtTerrainPatchObject contains the methods for loading a file as a terrain. When loading a file as a...
Definition: DtTerrainPatchObject.h:37
static const double theHeightAboveTerrainUpdatePeriod
Definition: DtOsgObserverObject.h:1141
bool myOrientToOnReset
Definition: DtOsgObserverObject.h:1496
bool myViewResolutionIncreasingState
Currently for 2D only, these variables will be ignored if projecting in 3D mode.
Definition: DtOsgObserverObject.h:1530
osg::Vec3d myObserverWorldEast
Definition: DtOsgObserverObject.h:1441
double mySceneCenterOffsetZ
Definition: DtOsgObserverObject.h:1414
MotionState myRotatingState
Definition: DtOsgObserverObject.h:1390
const osg::Vec3d & euler() const
Definition: DtOsgObserverObject.h:1344
osg::Matrixd myLevelObserverMimicRotationMatrix
Definition: DtOsgObserverObject.h:1235
double myAltitude
Definition: DtOsgObserverObject.h:1527
osg::Quat myAttachedRotation
Definition: DtOsgObserverObject.h:1232
osg::Vec3d myLevelObserverMimicFront
Definition: DtOsgObserverObject.h:1464
osg::Vec3d mySavedObserverOffsetVector
Used for switching between track mode and other attached modes.
Definition: DtOsgObserverObject.h:1189
osg::Vec3d myMasterPositionVector
Definition: DtOsgObserverObject.h:1176
bool myExternalSuppressConstrainToTerrain
suppress when told to
Definition: DtOsgObserverObject.h:1488
float myFlashlightAngle
Definition: DtOsgObserverObject.h:1558
bool myHideModelOnAttach
Definition: DtOsgObserverObject.h:1477
double myAttachedRoll
Definition: DtOsgObserverObject.h:1165
DT_DLL_vrfutil double angle(double vec1[3], double vec2[3])
bool myMovedSinceLastHAT
Definition: DtOsgObserverObject.h:1557
bool myLocalModelScalingEnabled
Definition: DtOsgObserverObject.h:1182
bool moving() const
Definition: DtOsgObserverObject.h:1309
Contains makVrv::DtObserverObject class.
bool myChanged
Definition: DtOsgObserverObject.h:1167
void applyRotation(double angle)
Definition: DtOsgObserverObject.h:1334
int myPartAttachment
Definition: DtOsgObserverObject.h:1161
osg::Quat myFinalCameraRotation
This is the combined camera/observer orientation; this is what the DtOsgChannel uses to orient itself...
Definition: DtOsgObserverObject.h:1428
Direction
Definition: DtOsgObserverObject.h:1259
This abstract base class defines the interface for OS-specific keyboard and mouse event listeners...
Definition: DtObserverObject.h:29
MotionState myAttachedObserverState
Definition: DtOsgObserverObject.h:1387
static const double theMaxTerrainRetryTime
Definition: DtOsgObserverObject.h:1143
MotionState myRotatingLevelState
Definition: DtOsgObserverObject.h:1391
osg::Vec3d my2DTo3DCachedObserverPosition
Definition: DtOsgObserverObject.h:1238
osg::Quat myMasterRotation
Definition: DtOsgObserverObject.h:1219
double myAttachedYaw
Definition: DtOsgObserverObject.h:1163
Class to manage disconnection of boost connections on deletion.
Definition: DtSignalConnectionManager.h:20
DtSignalConnectionManager myAttachmentBoundingVolumeSignals
Definition: DtOsgObserverObject.h:1157
osg::Vec3d myLastSpeedPositionVector
Definition: DtOsgObserverObject.h:1175
osg::Vec3d myLevelObserverUp
Definition: DtOsgObserverObject.h:1451
DtUniqueID myPendingTerrainPatchId
Definition: DtOsgObserverObject.h:1545
bool rotating() const
Definition: DtOsgObserverObject.h:1359
DtObserverObject::AttachType my3DAttachType
Definition: DtOsgObserverObject.h:1475
NorthType
Definition: DtObserverObject.h:56
double myHeightAboveTerrainTimer
Definition: DtOsgObserverObject.h:1480
double mySceneCenterOffsetY
Definition: DtOsgObserverObject.h:1413
osg::Vec3d myFinalCameraPositionVector
This is the combined camera/observer orientation; this is what the DtOsgChannel uses to orient itself...
Definition: DtOsgObserverObject.h:1432
bool myConstrainToCenter
This variable is true when the bounding radius is too big The reset view will be from far away trying...
Definition: DtOsgObserverObject.h:1250
bool myIsChangingDimension
Definition: DtOsgObserverObject.h:1244
double myCurvatureAdjustment
Definition: DtOsgObserverObject.h:1556
double myNextGotoTerrainCenterTime
Definition: DtOsgObserverObject.h:1543
static const double theMinViewResolution
Definition: DtOsgObserverObject.h:1149
Angle
Definition: DtOsgObserverObject.h:1324
MotionState myAbsoluteRotatingState
Definition: DtOsgObserverObject.h:1392
osg::Vec3d myObserverRotationalVelocityVector
Definition: DtOsgObserverObject.h:1180
osg::Vec3d myPreviousTerrainCenter
Definition: DtOsgObserverObject.h:1546
bool myMutableHaveDownIntersect
Definition: DtOsgObserverObject.h:1515
bool myForceOrientReset
Definition: DtOsgObserverObject.h:1500
void stop()
Definition: DtOsgObserverObject.h:1292
The DtCoordinateSystem is used to manage the current coordinate system of the scene.
Definition: DtCoordinateSystem.h:40
bool myOrientCameraToTargetConstraint
Definition: DtOsgObserverObject.h:1495
osg::Vec3d myObserverFront
Definition: DtOsgObserverObject.h:1448
osg::Vec3d myObserverWorldNorth
Definition: DtOsgObserverObject.h:1440
MotionState myLevelObserverState
Definition: DtOsgObserverObject.h:1386
bool myLookingTiltRight
Definition: DtOsgObserverObject.h:1423
osg::Vec3d myObserverOffsetVector
Current offset from an attachment, when attached.
Definition: DtOsgObserverObject.h:1186
double myLastTickTime
Definition: DtOsgObserverObject.h:1168
osg::Vec3d myPreviousPositionVector
for backing out if we hit a constraint
Definition: DtOsgObserverObject.h:1524
void clearAdvance()
Definition: DtOsgObserverObject.h:1299
bool moving(Direction d) const
Definition: DtOsgObserverObject.h:1314
osg::Vec3d myEuler
Definition: DtOsgObserverObject.h:1380
osg::Quat myCameraShakeRot
Definition: DtOsgObserverObject.h:1560
osg::Quat myFlashlightRotation
Flashlight orientation offset as a quaternion.
Definition: DtOsgObserverObject.h:1222
Base class to provide boost signal/slot management.
osg::Vec3d myViewIntersect
Definition: DtOsgObserverObject.h:1513
osg::Quat my2DTo3DCachedObserverRotation
Definition: DtOsgObserverObject.h:1240
osg::Vec3d myLevelObserverMimicRight
Definition: DtOsgObserverObject.h:1465
bool mySyncPending
Definition: DtOsgObserverObject.h:1177
osg::Vec3d myAdvance
This, when scaled, will provide the direction that the observer should move in as the result of tick-...
Definition: DtOsgObserverObject.h:1379
bool myLookingRight
-— Camera
Definition: DtOsgObserverObject.h:1419
osg::Vec3d myAttachedUp
Definition: DtOsgObserverObject.h:1455
DT_DLL_vrfutil double mag(double x[3])
osg::Vec3d myCameraOffset
This is the camera offset wrt to observer.
Definition: DtOsgObserverObject.h:1435
osg::Quat mySavedObserverRotation
This is used for switching between track mode and other attach modes.
Definition: DtOsgObserverObject.h:1225
A DtSceneObject represents an object that can be positioned in the scene by (possibly) attaching it t...
Definition: DtSceneObject.h:42
osg::Vec3d myLevelAttachedRight
Definition: DtOsgObserverObject.h:1461
double myRotationSpeed
Definition: DtOsgObserverObject.h:1404
double myLastAttachedBvolDiameter
Definition: DtOsgObserverObject.h:1520
bool mySyncSuppressed
Definition: DtOsgObserverObject.h:1178
void setMoving(Direction d, bool moving)
Definition: DtOsgObserverObject.h:1319
double myMinLinearSpeed
Definition: DtOsgObserverObject.h:1408
osg::Quat myObserverRotation
This is our ENU observer orientation as a quaternion.
Definition: DtOsgObserverObject.h:1218
double myAttachedPitch
Definition: DtOsgObserverObject.h:1164
Contains DLL export macros.
double myLastAttachBvolOffset
Definition: DtOsgObserverObject.h:1521
MotionState myObserverState
Definition: DtOsgObserverObject.h:1385
osg::Vec3d myObserverLinearVelocityVector
Definition: DtOsgObserverObject.h:1179
float myLocalModelScalingAmount
Definition: DtOsgObserverObject.h:1183
osg::Vec3d myAttachedWorldUp
Definition: DtOsgObserverObject.h:1443
bool stopped()
Definition: DtOsgObserverObject.h:1304
The DtDe is the core component of any VR-Vantage application. It owns a DtRenderer, DtDeCommunicator, as well as a DtDisplay and other things.
Definition: DtDe.h:70
std::vector< DtUniqueID > mySecondaryAttachments
Definition: DtOsgObserverObject.h:1160
osg::Vec3d myAttachPosition
Definition: DtOsgObserverObject.h:1518
osg::Vec3d myOrientToPosition
Definition: DtOsgObserverObject.h:1204
bool myOrbitingRight
Definition: DtOsgObserverObject.h:1398
double myLastViewMagnification
Definition: DtOsgObserverObject.h:1536
osg::Vec3d myAttachedPosition
Definition: DtOsgObserverObject.h:1197
double myOrbitSpeed
Definition: DtOsgObserverObject.h:1402
static const double theMaxViewResolution
Definition: DtOsgObserverObject.h:1152
MotionState myLevelAttachedObserverState
Definition: DtOsgObserverObject.h:1388
bool myConstrainToTerrain
Definition: DtOsgObserverObject.h:1482
bool myUsesBoundingVolumeForAttachedOffsets
Whether or not the observer is using bounding volumes for attached offsets. This is all the time for ...
Definition: DtOsgObserverObject.h:1508
double myCurrentViewMagnification
Only used in 3D.
Definition: DtOsgObserverObject.h:1535
osg::Vec3d myObserverRight
Definition: DtOsgObserverObject.h:1449
bool myOrbiting
Definition: DtOsgObserverObject.h:1497
osg::Vec3d myCameraFront
Definition: DtOsgObserverObject.h:1472
bool myLookingDown
Definition: DtOsgObserverObject.h:1422
This abstract base class defines the interface for OS-specific keyboard and mouse event listeners...
Definition: DtOsgObserverObject.h:48
osg::Vec3d myLevelObserverPosition
Gravity change in observer position this frame.
Definition: DtOsgObserverObject.h:1195
double myCurrentObserverDistance
largest of the distances currently in play in a given frame. This is how far we&#39;ll advance...
Definition: DtOsgObserverObject.h:1212
double mySpeedScaleSpeed
Definition: DtOsgObserverObject.h:1410
static const double theObserverBoundingSphere
Definition: DtOsgObserverObject.h:1140
osg::Vec3d myAttachedRight
Definition: DtOsgObserverObject.h:1457
osg::Vec3d & euler()
Definition: DtOsgObserverObject.h:1349
AttachType
Definition: DtObserverObject.h:36
MotionState()
Definition: DtOsgObserverObject.h:1270

Document ID: Generated on Thu Jun 1 17:58:13 EDT 2023 from SVN revision 255404
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)