VR-Forces 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) 2026 MAK Technologies, Inc.
3  * All rights reserved.
4  *****************************************************************************/
5 
9 
10 #pragma once
11 
12 #include <vrvOsg/vrvOsg.h>
14 
16 
18 #include <vrvUtil/DtQuat.h>
19 
20 #include <osg/Matrixd>
21 #include <osg/Vec3d>
22 #include <osg/Vec3>
23 #include <osg/Node>
24 
25 #include <list>
26 #include <unordered_map>
27 
28 class DtTaitBryan;
29 
30 namespace osg
31 {
32  class Node;
33 }
34 
35 namespace makVrv
36 {
37  class DtChannel;
38  class DtOsgChannel;
39  class DtCoordinateConverter;
40  class DtSceneObject;
41  class DtTerrainPatchObject;
42  class DtAgentUpdateResolverInterface;
43  class DtIntersectorsContainer;
44  class DtCoordinateSystem;
45 
50  {
51 
52  public:
53 
55  {
56  TerrainResultNoData = 0,
58  TerrainResultComplete
59  };
60 
61  public:
62 
64  DtOsgObserverObject( DtDe& de, DtUniqueID id, const std::string& name="" );
65 
67  virtual ~DtOsgObserverObject();
68 
70  DtOsgObserverObject() = delete;
71 
74 
76  DtOsgObserverObject& operator=(const DtOsgObserverObject&) = delete;
77 
78  public:
79 
81  virtual void tick( double simTime );
82 
84  virtual void tickAttachment();
85 
88  virtual void setModelSet( DtModelSetId modelSet );
89 
91  virtual double altitude() const;
92 
93  virtual void setNameAndRegister( const std::string& name );
94 
100  virtual void setCameraPositionAndOrientation( const osg::Vec3d& position,
101  const osg::Quat& rotation );
102 
103  virtual void getCameraPositionAndOrientation( osg::Vec3d& position,
104  osg::Quat& rotation ) const;
105 
106  virtual void getCameraPositionAndOrientation( DtVector& position,
107  DtQuat& rotation ) const;
108 
110  static void matrixdToTaitBryan( const osg::Matrixd& mat, DtTaitBryan& tb, bool isWorld2D = false );
111  static double clampUnity( double x );
112 
113 
114  //
115  //
117  //
118  //
119 
121  virtual void startMoveObserverRight();
124  virtual void stopMoveObserverRight();
125  virtual void moveObserverRight( double meters );
126 
128  virtual void startMoveObserverForward();
131  virtual void stopMoveObserverForward();
132  virtual void moveObserverForward( double meters );
134 
136  virtual void startMoveObserverUp();
139  virtual void stopMoveObserverUp();
140  virtual void moveObserverUp( double meters );
142 
144  virtual void startMoveObserverLeft();
147  virtual void stopMoveObserverLeft();
148  virtual void moveObserverLeft( double meters );
150 
152  virtual void startMoveObserverBack();
155  virtual void stopMoveObserverBack();
156  virtual void moveObserverBack( double meters );
158 
160  virtual void startMoveObserverDown();
163  virtual void stopMoveObserverDown();
164  virtual void moveObserverDown( double meters );
166 
168  virtual void startMoveLevelObserverRight();
172  virtual void stopMoveLevelObserverRight();
173  virtual void moveLevelObserverRight( double meters );
175 
177  virtual void startMoveLevelObserverForward();
181  virtual void stopMoveLevelObserverForward();
182  virtual void moveLevelObserverForward( double meters );
184 
186  virtual void startMoveLevelObserverUp();
190  virtual void stopMoveLevelObserverUp();
191  virtual void moveLevelObserverUp( double meters );
193 
195  virtual void startMoveLevelObserverLeft();
199  virtual void stopMoveLevelObserverLeft();
200  virtual void moveLevelObserverLeft( double meters );
202 
204  virtual void startMoveLevelObserverBack();
208  virtual void stopMoveLevelObserverBack();
209  virtual void moveLevelObserverBack( double meters );
211 
213  virtual void startMoveLevelObserverDown();
216  virtual void stopMoveLevelObserverDown();
217  virtual void moveLevelObserverDown( double meters );
219 
221  virtual void startMoveAttachedRight();
224  virtual void stopMoveAttachedRight();
225  virtual void moveAttachedRight( double meters );
226 
228  virtual void startMoveAttachedForward();
231  virtual void stopMoveAttachedForward();
232  virtual void moveAttachedForward( double meters );
234 
236  virtual void startMoveAttachedUp();
239  virtual void stopMoveAttachedUp();
240  virtual void moveAttachedUp( double meters );
242 
244  virtual void startMoveAttachedLeft();
247  virtual void stopMoveAttachedLeft();
248  virtual void moveAttachedLeft( double meters );
250 
252  virtual void startMoveAttachedBack();
255  virtual void stopMoveAttachedBack();
256  virtual void moveAttachedBack( double meters );
258 
260  virtual void startMoveAttachedDown();
263  virtual void stopMoveAttachedDown();
264  virtual void moveAttachedDown( double meters );
266 
268  virtual void startMoveLevelAttachedRight();
272  virtual void stopMoveLevelAttachedRight();
273  virtual void moveLevelAttachedRight( double meters );
275 
277  virtual void startMoveLevelAttachedForward();
281  virtual void stopMoveLevelAttachedForward();
282  virtual void moveLevelAttachedForward( double meters );
284 
286  virtual void startMoveLevelAttachedUp();
290  virtual void stopMoveLevelAttachedUp();
291  virtual void moveLevelAttachedUp( double meters );
293 
295  virtual void startMoveLevelAttachedLeft();
299  virtual void stopMoveLevelAttachedLeft();
300  virtual void moveLevelAttachedLeft( double meters );
302 
304  virtual void startMoveLevelAttachedBack();
308  virtual void stopMoveLevelAttachedBack();
309  virtual void moveLevelAttachedBack( double meters );
311 
313  virtual void startMoveLevelAttachedDown();
316  virtual void stopMoveLevelAttachedDown();
317  virtual void moveLevelAttachedDown( double meters );
319 
321  virtual void startMoveAttachedContextRight();
324  virtual void stopMoveAttachedContextRight();
325  virtual void moveAttachedContextRight( double meters );
327 
329  virtual void startMoveAttachedContextForward();
332  virtual void stopMoveAttachedContextForward();
333  virtual void moveAttachedContextForward( double meters );
335 
337  virtual void startMoveAttachedContextUp();
340  virtual void stopMoveAttachedContextUp();
341  virtual void moveAttachedContextUp( double meters );
343 
345  virtual void startMoveAttachedContextLeft();
348  virtual void stopMoveAttachedContextLeft();
349  virtual void moveAttachedContextLeft( double meters );
351 
353  virtual void startMoveAttachedContextBack();
356  virtual void stopMoveAttachedContextBack();
357  virtual void moveAttachedContextBack( double meters );
359 
361  virtual void startMoveAttachedContextDown();
363  virtual void stopMoveAttachedContextDown();
364  virtual void moveAttachedContextDown( double meters );
366 
368  virtual void startYawLeft();
371  virtual void stopYawLeft();
372  virtual void rotateYawLeft(double rads);
374 
376  virtual void startYawRight();
380  virtual void stopYawRight();
381  virtual void rotateYawRight(double rads);
383 
385  virtual void startPitchUp();
388  virtual void stopPitchUp();
389  virtual void rotatePitchUp( double rads );
390  virtual void rotateFlashlightPitchUp( double rads );
392 
394  virtual void startPitchDown();
397  virtual void stopPitchDown();
398  virtual void rotatePitchDown( double rads );
399  virtual void rotateFlashlightPitchDown( double rads );
401 
403  virtual void startRollLeft();
406  virtual void stopRollLeft();
407  virtual void rollLeft(double rads);
409 
411  virtual void startRollRight();
414  virtual void stopRollRight();
415  virtual void rollRight(double rads);
417 
419  virtual void startLevelYawLeft();
422  virtual void stopLevelYawLeft();
424 
426  virtual void startLevelYawRight();
430  virtual void stopLevelYawRight();
432 
434  virtual void startLevelPitchUp();
437  virtual void stopLevelPitchUp();
438  virtual void rotateLevelPitchUp(double rads);
440 
442  virtual void startLevelPitchDown();
445  virtual void stopLevelPitchDown();
446  virtual void rotateLevelPitchDown(double rads);
448 
450  virtual void startLevelRollLeft();
453  virtual void stopLevelRollLeft();
454  virtual void rollLevelLeft(double rads);
456 
458  virtual void startLevelRollRight();
461  virtual void stopLevelRollRight();
462  virtual void rollLevelRight(double rads);
464 
465  virtual void rotateLevelYawLeft( double rads );
466  virtual void rotateLevelYawRight( double rads );
467  virtual void rotateFlashlightYawLeft( double rads );
468  virtual void rotateFlashlightYawRight( double rads );
469 
470  virtual void startLookLeft();
471  virtual void stopLookLeft();
472  virtual void lookLeft( double rads );
473 
474  virtual void startLookRight();
475  virtual void stopLookRight();
476  virtual void lookRight( double rads );
477 
478  virtual void startLookUp();
479  virtual void stopLookUp();
480  virtual void lookUp( double rads );
481 
482  virtual void startLookDown();
483  virtual void stopLookDown();
484  virtual void lookDown( double rads );
485 
486  virtual void startLookTiltRight();
487  virtual void stopLookTiltRight();
488  virtual void lookTiltRight( double rads );
489 
490  virtual void startLookTiltLeft();
491  virtual void stopLookTiltLeft();
492  virtual void lookTiltLeft( double rads );
493 
495  virtual void startOrbitingLeft();
498  virtual void stopOrbitingLeft();
499  virtual void orbitLeft( double rads );
501 
503  virtual void startOrbitingRight();
506  virtual void stopOrbitingRight();
507  virtual void orbitRight( double rads );
509 
511  virtual void startOrbitingUp();
514  virtual void stopOrbitingUp();
515  virtual void orbitUp( double rads );
517 
519  virtual void startOrbitingDown();
522  virtual void stopOrbitingDown();
523  virtual void orbitDown( double rads );
525 
527  virtual void setLocation( double x, double y, double z);
528 
532  virtual void setAttachedLocation( double x, double y, double z ) override;
533  virtual void setAttachedX( double x ) override;
534  virtual void setAttachedY( double y ) override;
535  virtual void setAttachedZ( double z ) override;
536  virtual void getAttachedPosition( double& x, double& y, double& z ) const override;
537 
539  virtual void setOrientation( double psi, double theta, double phi );
540 
542  virtual void setTopographicOrientation( double psi, double theta, double phi );
543 
545  virtual void setOrientation( double x, double y, double z, double w);
546 
548  virtual void setAttachedOrientation( double psi, double theta, double phi ) override;
549  virtual void setAttachedYaw(double psi) override;
550  virtual void setAttachedPitch(double theta) override;
551  virtual void setAttachedRoll(double phi) override;
553  virtual void getAttachedOrientation(double& psi, double& theta, double& phi) const override;
555  virtual void getAttachedOrientationByDecomp(double& psi, double& theta, double& phi) const;
556 
558  virtual void setAttachedOrientation( double x, double y, double z,
559  double w);
560 
563  void setLocalModelScalingEnabled( bool enabled );
564 
567  void setLocalModelScalingAmount( float amount );
568 
571  virtual void jumpTo( double x, double y, double z );
572 
574  virtual void jumpTo( DtUniqueID elementID );
575 
576  virtual void orientTo( double x, double y, double z );
577 
579  virtual void dragTerrain( double lastX, double lastY, double lastZ,
580  double currX, double currY, double currZ );
581 
582  virtual void dragTerrain2( double myStartDragX, double myStartDragY,
583  double myStartDragZ, int deltaMouseX, int deltaMouseY );
584 
585  virtual void dragGravityUp( double windowUnits );
586  virtual void dragGravityDown( double windowUnits );
587  virtual void dragGravityLeft( double windowUnits );
588  virtual void dragGravityRight( double windowUnits );
589  virtual void scrollObserverForward( int wheelUnits );
590  virtual void scrollObserverBack( int wheelUnits );
591  virtual void scrollLevelObserverForward( int wheelUnits );
592  virtual void scrollLevelObserverBack( int wheelUnits );
593 
594  virtual void scrollFlashlightWider( int wheelUnits );
595  virtual void scrollFlashlightNarrower( int wheelUnits );
596 
598  virtual float flashlightAngle();
599 
600  //{@
602  virtual void startIncreasingViewResolution();
603  virtual void stopIncreasingViewResolution();
604  virtual void increaseViewResolution();
605 
606  virtual void startDecreasingViewResolution();
607  virtual void stopDecreasingViewResolution();
608  virtual void decreaseViewResolution();
609 
610  // Sets the view resolution in meters per pixel.
611  virtual void setViewResolution( double resolution);
612 
613  // Get the current view resolution.
614  virtual double viewResolution() const override;
615 
621  virtual void setCurrentViewMagnification( double mag );
622 
624  virtual double currentViewMagnification() const;
625 
627 
628  //
630  //
631 
633  virtual void setOrbitSpeed( double speed );
634 
636  virtual void setLinearSpeed( double speed );
637 
639  virtual void setRotationSpeed( double speed );
640 
642  virtual void setMinLinearSpeed( double minSpeed );
643 
645  virtual void setMaxLinearSpeed( double maxSpeed );
646 
648  virtual void setLinearScaledSpeedGain( double gain );
649 
655  virtual void gotoTerrainCenter( DtUniqueID terrainPatch, bool retry );
656 
658  virtual void resetAttachment();
659 
660  virtual void resetOrientation();
661 
663  virtual void resetCamera();
664  virtual void level();
665 
666  virtual void stopAll();
667 
668  virtual void attachToObjects( const std::vector<DtUniqueID>& elementIds );
669  virtual void setSecondaryAttachment( const std::vector<DtUniqueID>& elementIds );
670  virtual void setLocationTrackAttachment( const osg::Vec3d& location );
671  virtual void setLocationTrackAttachment( double x, double y, double z );
672 
673  virtual void attachToPart( int partId);
674  virtual void detach();
675  virtual void setAttachType( DtObserverObject::AttachType type );
676  virtual void setHideModelOnAttach( bool hide );
677 
680  virtual void setUsesBoundingVolumeForAttachedOffsets(bool useBoundingVolume);
681 
684  virtual bool usesBoundingVolumeForAttachedOffsets() const;
685 
689  virtual void setAttachmentHas3DCockpit( bool cockpit );
690 
691  virtual void scaleCurrentAttachments( bool scaled );
692  virtual void setOrientToTargetConstraint( bool orient );
693  virtual void setOrbiting( bool orbit );
694  virtual void setOrientCameraToTargetConstraint( bool orient );
695 
696  virtual void setConstrainToTerrain( bool trueFalse );
697  virtual void setConstrainToCenter( bool trueFalse );
698 
701  virtual void suppressConstrainToTerrain( bool trueFalse );
702 
703  virtual void setSpeedScaling( bool trueFalse );
704 
706  virtual void setSpeedScaledSpeed( double speed );
707 
709  virtual void getLocation(double &x, double &y, double& z) const;
711  virtual void getObserverPosition(double &x, double &y, double& z) const;
712  virtual void getEffectiveLocation(double &x, double &y, double& z) const;
714 
716  virtual void getObserverCameraPosition(double& x, double& y, double& z) const;
717 
719  virtual void getOrientation( double& psi, double& theta, double& phi ) const;
720 
723  virtual void getObserverCameraOrientation(double& psi, double& theta, double& phi, bool includeShake) const;
724 
726  virtual void getTopographicOrientation( double& psi, double& theta, double& phi ) const;
727 
728  virtual void getOrientation( double& x, double& y, double& z, double& w ) const;
729 
730  virtual void getFlashlightOrientation( double& x, double& y, double& z, double& w ) const;
731 
734  virtual void getObserverPlatformFront(double& x, double& y, double& z) const;
735 
738  virtual void getObserverPlatformUp(double& x, double& y, double& z) const;
739 
742  virtual void getObserverPlatformRight(double& x, double& y, double& z) const;
743 
746  virtual void getObserverCameraFront(double& x, double& y, double& z, bool includeShake) const;
747 
749  virtual void getObserverCameraUp(double& x, double& y, double& z, bool includeShake) const;
750 
752  virtual void getObserverCameraRight(double& x, double& y, double& z, bool includeShake) const;
753 
754  virtual void getCameraUp(double& x, double& y, double& z);
755 
756  virtual void getCameraFront(double& x, double& y, double& z);
757 
758  virtual void getCameraRight(double& x, double& y, double& z);
759 
761  virtual void setCameraShakeRotation(double x, double y, double z, double w);
762 
764  virtual void getCameraShakeRotation(double& x, double& y, double& z, double& w);;
765 
768 // virtual double calculate2DAltitude();
769 
770 
773  virtual double heightAboveTerrainFromCurrentZoom(double magnification = 1.) const;
774 
778  virtual double altitudeFromCurrentZoom(double magnification=1.) const;
779 
782  virtual double zoomFromHeightAboveTerrain(double hat, double magnification=1) const;
783 
786  virtual double zoomFromAltitude(double altitude, double magnification=1.) const;
787 
788 
792  virtual double zoomFromCurrentAltitude() const;
793 
796  virtual double topographicHeading() const;
797 
799  virtual void getLinearVelocity(double &x, double &y, double &z) const;
800 
802  virtual void getRotationalVelocity( double& x, double& y, double& z) const;
803 
807  virtual void setModeSetting( int setting, bool value );
808 
811  virtual void setNorthType(DtObserverObject::NorthType northType);
812 
814  virtual std::vector<DtUniqueID> currentAttachments() const;
815 
818 
819  virtual const osg::Vec3d& locationTrackAttachmentVec3d() const;
820  virtual void getLocationTrackAttachment( double& x, double& y, double& z ) const;
822 
826  virtual DtObserverObject::AttachType attachType3D() const;
827 
831  virtual DtObserverObject::AttachType attachType2D() const;
832 
834  virtual bool attachedObjectHidden() const;
835 
839  virtual bool attachmentHas3DCockpit() const;
840 
843  virtual osg::Vec3d attachedOffsetVector() const;
844 
849  virtual double attachedNearClipOffset() const;
850 
852  virtual double heightAboveTerrain() const;
853 
855  virtual double heightOfTerrain() const;
856 
858  virtual const DtIntersectorsContainer* intersectorsContainer(void) const;
859 
861  virtual DtIntersectorsContainer* intersectorsContainer(void);
862 
863  protected:
864 
866  virtual bool shouldOrientToGlobeCenter();
867 
869  virtual void adjustToGlobeCurvature();
870 
872  virtual bool shouldRotateGlobe();
873 
874  virtual void calcObserverWorldVectors();
875  virtual const osg::Vec3d& observerWorldUp() const;
876  virtual const osg::Vec3d& observerWorldNorth() const;
877  virtual const osg::Vec3d& observerWorldEast() const;
878 
879  virtual const osg::Vec3d& attachedWorldUp() const;
880 
881  virtual osg::Vec3d& observerUp();
882  virtual osg::Vec3d& observerFront();
883  virtual osg::Vec3d& observerRight();
884  virtual void observerBasis(osg::Vec3d& up, osg::Vec3d& front, osg::Vec3d& right);
885 
886  virtual osg::Vec3d& attachedUp();
887  virtual osg::Vec3d& attachedFront();
888  virtual osg::Vec3d& attachedRight();
889 
890  virtual osg::Vec3d& attachedOffsetUp();
891  virtual osg::Vec3d& attachedOffsetFront();
892  virtual osg::Vec3d& attachedOffsetRight();
893 
895  virtual osg::Vec3d& levelAttachedUp();
896  virtual osg::Vec3d& levelAttachedFront();
897  virtual osg::Vec3d& levelAttachedRight();
898 
900  virtual osg::Vec3d& levelObserverMimicUp();
901  virtual osg::Vec3d& levelObserverMimicFront();
902  virtual osg::Vec3d& levelObserverMimicRight();
903 
904  virtual osg::Vec3d& cameraUp();
905  virtual osg::Vec3d& cameraFront();
906  virtual osg::Vec3d& cameraRight();
907 
908  virtual osg::Vec3d& levelObserverUp();
909  virtual osg::Vec3d& levelObserverFront();
910  virtual osg::Vec3d& levelObserverRight();
911 
912  virtual void advanceOrbitLeft( double rads );
913  virtual void advanceOrbitRight( double rads );
914  virtual void advanceOrbitUp( double rads );
915  virtual void advanceOrbitDown( double rads );
916 
917  virtual void makeLevelObserverMatrix();
918 
920  virtual void calculateLevelAttachedRotation();
921 
923  virtual void makeLevelObserverMimicMatrix();
924 
928  virtual osg::Vec3d calcWorldPositionChange();
929 
930  virtual osg::Vec3d calcMimicPositionChange();
931 
932  virtual osg::Vec3d calcAttachedPosition(const osg::Quat& attInverse, const osg::Vec3d& attachedAdvance);
933  virtual osg::Vec3d calcAttachedAdvance(const osg::Quat& tetherTrackInverse);
934 
935  virtual osg::Vec3d calcFollowPositionChange();
936  virtual osg::Vec3d calcSpaceFollowPositionChange();
937  virtual osg::Vec3d calcTetherPositionChange();
938  virtual osg::Vec3d calcTetherTrackPositionChange();
939 
940  virtual osg::Vec3d calcTrackPositionChange();
941  virtual osg::Quat calcTetherTrackRotation();
942 
943  virtual osg::Quat calcFlashlightOrientationChange();
944  virtual osg::Quat calcWorldOrientationChange();
945  virtual osg::Quat calcTetherOrientationChange();
946  virtual osg::Quat calcMimicOrientationChange();
947  virtual osg::Quat calcFollowOrientationChange();
948 
949  virtual void setCurrentAttachmentsVisibility( bool visible );
950 
957 
960  virtual void orientTo( const osg::Vec3d& target );
961 
963  virtual void orientCameraTo( const osg::Vec3d& target );
964 
965  virtual TerrainResult getTerrainCenter( const DtUniqueID& patchID, osg::Vec3d& center );
966 
967  virtual DtCoordinateConverter& coordinateConverter();
968  virtual const DtCoordinateConverter& coordinateConverter() const;
969 
970  virtual void initializeAttachment();
971 
972  virtual const osg::Vec3d& scalingIntersection() const;
973  virtual void getViewIntersection();
974 
976  virtual double linearSpeed();
977 
979  virtual double speedScalingGain() const;
980 
981  virtual void calcTerrainConstraint(const osg::Vec3d& prev );
982 
988  virtual bool updateAttachPositionAndOrientation();
989 
990  virtual bool getSecondaryAttachPosition( osg::Vec3d& position );
991 
992  virtual void getObserverOffsetVector( double& x, double& y, double& z ) const;
993  virtual void setObserverOffsetVector( double x, double y, double z );
994 
997 
998  virtual void getCameraFromParentOffsetVector( double& x, double& y, double& z ) const;
999  virtual void getCameraFromParentRotationOffset( double& x, double& y, double& z, double& w ) const;
1001 
1002  virtual void getAttachedRotationOffset( double& x, double& y, double& z, double& w ) const;
1003  virtual void setAttachedRotationOffset( double x, double y, double z,
1004  double w );
1005 
1006  virtual void getBoundingVolume( DtSceneObject& sceneObject,
1007  osg::Vec3& bvolExtents, osg::Vec3d& bvolCenter );
1008 
1009  virtual void getBoundingVolume( DtTerrainPatchObject& patchObject,
1010  osg::Vec3& bvolExtents, osg::Vec3d& bvolCenter );
1011 
1012  virtual void setLocation( const osg::Vec3d& location, bool suppress=true );
1013 
1014  virtual bool isMoving() const;
1015  virtual bool isRotating() const;
1016 
1017  virtual double computeNearClipDistance( DtSceneObject* sceneObject );
1018  virtual float computeLocalModelScalingAmount( DtSceneObject* sceneObject );
1019 
1020  virtual void calcScaledSpeed();
1021  virtual bool getTerrainOrPropIntersection( const osg::Vec3d& startPos,
1022  const osg::Vec3d& endPos, osg::Vec3d& result, const osg::Node::NodeMask mask = ~DtOsgNodeFlags::FlagSupportOff) const;
1023 
1025  virtual DtSceneObject* findSceneObjectFromElement(const DtElementID& id);
1026 
1028  virtual DtTerrainPatchObject* findTerrainPatchObjectFromElement( DtElementID id );
1029  virtual DtOsgObserverObject* findObserverObjectFromElement( DtElementID id );
1030 
1031  virtual void getPositionAndOrientation( DtSceneObject& sceneObject, osg::Vec3d& position,
1032  osg::Vec3d& orientToPosition, osg::Quat& orientation );
1033 
1034  virtual void getPositionAndOrientation( DtTerrainPatchObject& patchObject, osg::Vec3d& position,
1035  osg::Vec3d& orientToPosition, osg::Quat& orientation );
1036 
1037  virtual void getPositionAndOrientation( DtOsgObserverObject& observerObject, osg::Vec3d& position,
1038  osg::Vec3d& orientToPosition, osg::Quat& orientation );
1039 
1041  virtual void getPositionFromSceneObject( DtSceneObject& sceneObject, osg::Vec3d& position ) const;
1042 
1044  virtual void getPositionFromObserverObject( DtOsgObserverObject& observerObject, osg::Vec3d& position ) const;
1045 
1048  virtual bool getPartPositionOriFromSceneObject( DtSceneObject& sceneObject,
1049  int partId, osg::Vec3d& position, osg::Quat& ori ) const;
1050 
1053  virtual void force2D();
1054 
1056  virtual void dimensionChanged( bool is2D );
1057  virtual void setIs2D( bool is2D );
1058 
1060  virtual double calculate3DAltitude() const;
1061 
1063  virtual void calculateAltitude();
1064 
1065  // Sends the location of the observer on the master to all others; only used
1066  // if different
1067  virtual void synchronizeLocation( double x, double y, double z );
1068 
1069  // Sends the orientation of the observer on the master to all others; only used
1070  // if different
1071  virtual void synchronizeOrientation( double x, double y, double z, double w );
1072 
1088  virtual void calcHeightAboveTerrain(bool force=false);
1089 
1091  std::list<DtChannel*> findChannels();
1094  std::list<const DtChannel*> findChannels() const;
1096 
1105  virtual double frustumPixelHeight() const;
1106 
1108  virtual void slot_coordinateSystemChanged();
1109 
1111  virtual void cache3DOffsetAndRotation();
1112 
1114  virtual void restoreAttachOffsetsFrom3DCache();
1115 
1116 
1119  virtual void slot_dateChanged();
1120 
1123  virtual bool getAttachedToBoundingVolume(DtSceneObject* const sceneObject, osg::Vec3d& boundingVolumeCenter, osg::Vec3& boundingVolumeExtents,
1124  double& maxOffset, double& maxExtent);
1125 
1128  virtual bool setupAttachOffsetsAfterReset(DtSceneObject* const sceneObject, osg::Vec3d boundingVolumeCenter, osg::Vec3 boundingVolumeExtents,
1129  double maxOffset, double maxExtent);
1130 
1134  virtual void setupAttachOffsets(double maxExtent);
1135 
1138  virtual void reinitializeAfterBoundingVolumeChange();
1139 
1142  virtual void resetAfterBoundingVolumeChange();
1143 
1145  virtual void disableBuoyancyForAttachedEntities(bool disable, bool forceReset) override;
1146 
1147  protected:
1148 
1149  static const double theObserverBoundingSphere;
1151 
1152  static const double theMaxTerrainRetryTime;
1153 
1154  // below this altitude, ignore myConstrainToCenter
1155  static const double theCenterConstrainHeight;
1156 
1157  // Zoom won't get any smaller than this
1158  static const double theMinViewResolution;
1159 
1160  // Zoom won't get any larger than this
1161  static const double theMaxViewResolution;
1162 
1163 
1164  protected:
1165 
1167 
1168  std::vector<DtUniqueID> myCurrentAttachments;
1169  std::vector<DtUniqueID> mySecondaryAttachments;
1171 
1175 
1178 
1179  //
1181  //
1190 
1193 
1196 
1199 
1202 
1205 
1207 
1209 
1211  osg::Vec3d myDragMove;
1212 
1214 
1215  osg::Vec3d myOrbitAdvance;
1216 
1222 
1225 
1228  osg::Quat myMasterRotation;
1229 
1232 
1235 
1240 
1243 
1246 
1251 
1257 
1258  //bool myGlobeObserverMode;
1260 
1263 
1265  {
1266  public:
1267 
1269  {
1270  Stopped = 0,
1271  Forward = 1,
1272  Backward = 2,
1273  Left = 4,
1274  Right = 8,
1275  Up = 16,
1276  Down = 32
1277  };
1278 
1280  : myState(Stopped)
1281  {
1282  }
1283 
1285  inline void applyMovement(double linearDistance)
1286  {
1287  if(moving(Right)) myAdvance[0] += linearDistance;
1288  if(moving(Left)) myAdvance[0] -= linearDistance;
1289  if(moving(Forward)) myAdvance[1] += linearDistance;
1290  if(moving(Backward)) myAdvance[1] -= linearDistance;
1291  if(moving(Up)) myAdvance[2] += linearDistance;
1292  if(moving(Down)) myAdvance[2] -= linearDistance;
1293  }
1294 
1296  inline const osg::Vec3d& advance() const
1297  {
1298  return myAdvance;
1299  }
1300 
1301  inline void stop()
1302  {
1303  myState = Stopped;
1304  myAdvance.set(0.0,0.0,0.0);
1305  myEuler.set(0.0,0.0,0.0);
1306  }
1307 
1308  inline void clearAdvance()
1309  {
1310  myAdvance.set(0.0,0.0,0.0);
1311  }
1312 
1313  inline bool stopped()
1314  {
1315  return myState == Stopped;
1316  }
1317 
1318  inline bool moving() const
1319  {
1320  return myState != Stopped;
1321  }
1322 
1323  inline bool moving(Direction d) const
1324  {
1325  return (myState & d) != 0;
1326  }
1327 
1328  inline void setMoving(Direction d, bool moving)
1329  {
1330  myState = moving ? myState | d : myState & ~d;
1331  }
1332 
1333  enum Angle
1334  {
1335  YawLeft = 1,
1336  YawRight = 2,
1337  PitchUp = 4,
1338  PitchDown = 8,
1339  RollLeft = 16,
1340  RollRight = 32
1341  };
1342 
1343  inline void applyRotation(double angle)
1344  {
1345  if(rotating(YawRight)) myEuler[0] -= angle;
1346  if(rotating(YawLeft)) myEuler[0] += angle;
1347  if(rotating(PitchUp)) myEuler[1] += angle;
1348  if(rotating(PitchDown)) myEuler[1] -= angle;
1349  if(rotating(RollRight)) myEuler[2] += angle;
1350  if(rotating(RollLeft)) myEuler[2] -= angle;
1351  }
1352 
1353  inline const osg::Vec3d& euler() const
1354  {
1355  return myEuler;
1356  }
1357 
1358  inline osg::Vec3d& euler()
1359  {
1360  return myEuler;
1361  }
1362 
1363  inline void level()
1364  {
1365  myEuler.set(0.0,0.0,0.0);
1366  }
1367 
1368  inline bool rotating() const
1369  {
1370  return myState != Stopped;
1371  }
1372 
1373  inline bool rotating( Angle d ) const
1374  {
1375  return (myState & d) != 0;
1376  }
1377 
1378  inline void setRotating( Angle d, bool rotating )
1379  {
1380  myState = rotating ? myState | d : myState & ~d;
1381  }
1382 
1383  protected:
1384 
1388  osg::Vec3d myAdvance;
1389  osg::Vec3d myEuler;
1390 
1391  unsigned char myState;
1392  };
1393 
1398 
1403 
1405 
1410 
1414 
1420 
1424 
1425  //
1434 
1438 
1442 
1444  osg::Vec3d myCameraOffset;
1446  osg::Quat myCameraRotation;
1447 
1448  osg::Vec3d myObserverWorldUp;
1451 
1452  osg::Vec3d myAttachedWorldUp;
1455 
1456  osg::Vec3d myObserverUp;
1457  osg::Vec3d myObserverFront;
1458  osg::Vec3d myObserverRight;
1459 
1460  osg::Vec3d myLevelObserverUp;
1463 
1464  osg::Vec3d myAttachedUp;
1465  osg::Vec3d myAttachedFront;
1466  osg::Vec3d myAttachedRight;
1467 
1468  osg::Vec3d myLevelAttachedUp;
1471 
1475 
1479 
1480  osg::Vec3d myCameraUp;
1481  osg::Vec3d myCameraFront;
1482  osg::Vec3d myCameraRight;
1483 
1485 
1490 
1492 
1495 
1498 
1507  // force an orientation reset AFTER the next time the observer position is updated
1508  // Needed when making large attach jumps
1510 
1518 
1520 
1522  osg::Vec3d myViewIntersect;
1523 
1525  mutable osg::Vec3d myMutableDownIntersect;
1526 
1527  osg::Vec3d myAttachPosition;
1528 
1531 
1535 
1536  double myAltitude;
1537 
1542 
1546 
1547  typedef std::unordered_map<DtElementID, bool> ElementVisibilityMap;
1549 
1550  // Paged terrain initialization
1558 
1559  // Used for speed scaling, this is the same as myHeightAboveTerrain
1560  // when unattached, but the distance from the attached entity when
1561  // attached
1563 
1564  // curvature adjustment
1568 
1569  osg::Quat myCameraShakeRot;
1570 
1572 
1573  DtIntersectorsContainer* myIntersectors = nullptr;
1574 
1576 
1579  DtCoordinateSystem* myCoordinateSystem = nullptr;
1580  };
1581 
1582 }
osg::Quat myCameraRotation
This is the camera (wrt the observer) as a quaternion.
Definition: DtOsgObserverObject.h:1446
osg::Vec3d myDragMove
Change in world position due to drag.
Definition: DtOsgObserverObject.h:1211
osg::Vec3d myMutableDownIntersect
Definition: DtOsgObserverObject.h:1525
Definition: DtOsgObserverObject.h:57
bool myHaveViewIntersect
Definition: DtOsgObserverObject.h:1521
void setRotating(Angle d, bool rotating)
Definition: DtOsgObserverObject.h:1378
ElementVisibilityMap myPendingVisibilityState
Definition: DtOsgObserverObject.h:1548
bool myAttachmentHas3DCockpit
Definition: DtOsgObserverObject.h:1487
Icon appears in the right zone of the status bar.
osg::Vec3d myLevelObserverMimicUp
Definition: DtOsgObserverObject.h:1472
osg::Vec3d myAttachedWorldEast
Definition: DtOsgObserverObject.h:1454
bool myHave3DOffsetCache
Definition: DtOsgObserverObject.h:1252
int myOrientToTargetConstraint
This is an int rather than a bool because we increment/decrement it, much like a reference pointer...
Definition: DtOsgObserverObject.h:1503
osg::Vec3d myObserverUp
Definition: DtOsgObserverObject.h:1456
double myHeightOfTerrain
Definition: DtOsgObserverObject.h:1557
std::vector< DtUniqueID > myCurrentAttachments
Definition: DtOsgObserverObject.h:1168
double myStartGotoTerrainCenterTime
Definition: DtOsgObserverObject.h:1553
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:1242
osg::Vec3d myAttachedOffsetUp
Definition: DtOsgObserverObject.h:1476
osg::Vec3d myAttachedOffsetRight
Definition: DtOsgObserverObject.h:1478
osg::Vec3d myOrbitAdvance
Definition: DtOsgObserverObject.h:1215
DtCoordinateConverter is the base class for &#39;local (cig) to geocentric&#39; converters.
Definition: DtCoordinateConverter.h:25
osg::Vec3d myCameraRight
Definition: DtOsgObserverObject.h:1482
osg::Vec3d myCameraUp
Definition: DtOsgObserverObject.h:1480
double myHeightAboveTerrain
Definition: DtOsgObserverObject.h:1556
double myMaxLinearSpeed
Need just these, for terrain scaling.
Definition: DtOsgObserverObject.h:1416
#define DT_DLL_VRVOSG
Definition: vrvOsg.h:23
double myLinearSpeed
Definition: DtOsgObserverObject.h:1412
This form is used for doing level (&#39;flying carpet&#39;) style movements.
Definition: DtOsgObserverObject.h:1264
Icon appears in the left zone of the status bar.
osg::Vec3d myLevelAttachedFront
Definition: DtOsgObserverObject.h:1469
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:1406
osg::Vec3d myObserverPosition
Change in observer position this frame.
Definition: DtOsgObserverObject.h:1201
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:37
MotionState myFlashlightRotatingState
Definition: DtOsgObserverObject.h:1404
osg::Vec3d myLocationAttachPoint
Definition: DtOsgObserverObject.h:1571
osg::Vec3d my2DTo3DCachedObserverOffsetVector
Definition: DtOsgObserverObject.h:1248
osg::Vec3d myLevelAttachedPosition
Definition: DtOsgObserverObject.h:1208
double mySceneCenterOffsetX
Definition: DtOsgObserverObject.h:1421
void level()
Definition: DtOsgObserverObject.h:1363
bool mySpeedScaling
Definition: DtOsgObserverObject.h:1488
bool myViewResolutionDecreasingState
Definition: DtOsgObserverObject.h:1540
osg::Vec3d myLevelObserverFront
Definition: DtOsgObserverObject.h:1461
double myViewResolution
Definition: DtOsgObserverObject.h:1541
bool myLookingUp
Definition: DtOsgObserverObject.h:1430
osg::Vec3d myAttachedOffsetFront
Definition: DtOsgObserverObject.h:1477
osg::Matrixd myLevelObserverRotationMatrix
Definition: DtOsgObserverObject.h:1245
bool myOrbitingUp
Definition: DtOsgObserverObject.h:1408
static const double theCenterConstrainHeight
Definition: DtOsgObserverObject.h:1155
void applyMovement(double linearDistance)
Update the advance based upon the movement.
Definition: DtOsgObserverObject.h:1285
std::unordered_map< DtElementID, bool > ElementVisibilityMap
Definition: DtOsgObserverObject.h:1547
TerrainResult
Definition: DtOsgObserverObject.h:54
bool myOrbitingDown
Definition: DtOsgObserverObject.h:1409
bool myInternalSuppressConstrainToTerrain
suppress when jumping...
Definition: DtOsgObserverObject.h:1494
osg::Vec3d myObserverWorldUp
Definition: DtOsgObserverObject.h:1448
bool rotating(Angle d) const
Definition: DtOsgObserverObject.h:1373
osg::Vec3d myAttachedWorldNorth
Definition: DtOsgObserverObject.h:1453
osg::Vec3d myLevelObserverRight
Definition: DtOsgObserverObject.h:1462
bool myHaveTerrainPivot
Definition: DtOsgObserverObject.h:1519
const osg::Vec3d & advance() const
Get the current movement advance.
Definition: DtOsgObserverObject.h:1296
osg::Vec3d myAttachedFront
Definition: DtOsgObserverObject.h:1465
osg::Vec3d myLevelAttachedUp
Definition: DtOsgObserverObject.h:1468
osg::Quat myAttachedRotationOffset
My Attached rotation offset.
Definition: DtOsgObserverObject.h:1224
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:1239
DtUniqueID DtElementID
The ElementID is a specific type of unique ID used to represent VR-Vantage uniquely defined elements...
Definition: DtUniqueID.h:23
double mySpeedScaleHeightEquivalent
Definition: DtOsgObserverObject.h:1562
MotionState myAbsoluteLevelRotatingState
Definition: DtOsgObserverObject.h:1402
osg::Quat my2DTo3DCachedObserverRotationOffset
Definition: DtOsgObserverObject.h:1250
unsigned char myState
Definition: DtOsgObserverObject.h:1391
bool myLookingTiltLeft
Definition: DtOsgObserverObject.h:1433
DtSignalConnectionManager myConnections
Definition: DtOsgObserverObject.h:1575
double myLinearScaledSpeedGain
Definition: DtOsgObserverObject.h:1418
osg::Vec3d myObserverPositionVector
— Observer
Definition: DtOsgObserverObject.h:1183
bool myLookingLeft
Definition: DtOsgObserverObject.h:1429
osg::Vec3d myPreviousOffsetVector
Definition: DtOsgObserverObject.h:1534
bool myGotoTerrainCenterPending
Definition: DtOsgObserverObject.h:1551
A DtTerrainPatchObject contains the methods for loading a file as a terrain. When loading a file as a...
Definition: DtTerrainPatchObject.h:35
static const double theHeightAboveTerrainUpdatePeriod
Definition: DtOsgObserverObject.h:1150
bool myOrientToOnReset
Definition: DtOsgObserverObject.h:1505
bool myViewResolutionIncreasingState
Currently for 2D only, these variables will be ignored if projecting in 3D mode.
Definition: DtOsgObserverObject.h:1539
osg::Vec3d myObserverWorldEast
Definition: DtOsgObserverObject.h:1450
double mySceneCenterOffsetZ
Definition: DtOsgObserverObject.h:1423
MotionState myRotatingState
Definition: DtOsgObserverObject.h:1399
const osg::Vec3d & euler() const
Definition: DtOsgObserverObject.h:1353
osg::Matrixd myLevelObserverMimicRotationMatrix
Definition: DtOsgObserverObject.h:1244
double myAltitude
Definition: DtOsgObserverObject.h:1536
osg::Quat myAttachedRotation
Definition: DtOsgObserverObject.h:1241
osg::Vec3d myLevelObserverMimicFront
Definition: DtOsgObserverObject.h:1473
osg::Vec3d mySavedObserverOffsetVector
Used for switching between track mode and other attached modes.
Definition: DtOsgObserverObject.h:1198
osg::Vec3d myMasterPositionVector
Definition: DtOsgObserverObject.h:1185
bool myExternalSuppressConstrainToTerrain
suppress when told to
Definition: DtOsgObserverObject.h:1497
float myFlashlightAngle
Definition: DtOsgObserverObject.h:1567
bool myHideModelOnAttach
Definition: DtOsgObserverObject.h:1486
double myAttachedRoll
Definition: DtOsgObserverObject.h:1174
DT_DLL_vrfutil double angle(double vec1[3], double vec2[3])
bool myMovedSinceLastHAT
Definition: DtOsgObserverObject.h:1566
bool myLocalModelScalingEnabled
Definition: DtOsgObserverObject.h:1191
bool moving() const
Definition: DtOsgObserverObject.h:1318
Contains makVrv::DtObserverObject class declaration.
bool myChanged
Definition: DtOsgObserverObject.h:1176
void applyRotation(double angle)
Definition: DtOsgObserverObject.h:1343
int myPartAttachment
Definition: DtOsgObserverObject.h:1170
osg::Quat myFinalCameraRotation
This is the combined camera/observer orientation; this is what the DtOsgChannel uses to orient itself...
Definition: DtOsgObserverObject.h:1437
Direction
Definition: DtOsgObserverObject.h:1268
This abstract base class defines the interface for OS-specific keyboard and mouse event listeners...
Definition: DtObserverObject.h:35
MotionState myAttachedObserverState
Definition: DtOsgObserverObject.h:1396
static const double theMaxTerrainRetryTime
Definition: DtOsgObserverObject.h:1152
MotionState myRotatingLevelState
Definition: DtOsgObserverObject.h:1400
osg::Vec3d my2DTo3DCachedObserverPosition
Definition: DtOsgObserverObject.h:1247
osg::Quat myMasterRotation
Definition: DtOsgObserverObject.h:1228
double myAttachedYaw
Definition: DtOsgObserverObject.h:1172
Class to manage disconnection of boost connections on deletion.
Definition: DtSignalConnectionManager.h:20
DtSignalConnectionManager myAttachmentBoundingVolumeSignals
Definition: DtOsgObserverObject.h:1166
osg::Vec3d myLastSpeedPositionVector
Definition: DtOsgObserverObject.h:1184
osg::Vec3d myLevelObserverUp
Definition: DtOsgObserverObject.h:1460
Contains makVrv::DtQuat class.
DtUniqueID myPendingTerrainPatchId
Definition: DtOsgObserverObject.h:1554
bool rotating() const
Definition: DtOsgObserverObject.h:1368
DtObserverObject::AttachType my3DAttachType
Definition: DtOsgObserverObject.h:1484
NorthType
Definition: DtObserverObject.h:62
double myHeightAboveTerrainTimer
Definition: DtOsgObserverObject.h:1489
double mySceneCenterOffsetY
Definition: DtOsgObserverObject.h:1422
osg::Vec3d myFinalCameraPositionVector
This is the combined camera/observer orientation; this is what the DtOsgChannel uses to orient itself...
Definition: DtOsgObserverObject.h:1441
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:1259
bool myIsChangingDimension
Definition: DtOsgObserverObject.h:1253
double myCurvatureAdjustment
Definition: DtOsgObserverObject.h:1565
double myNextGotoTerrainCenterTime
Definition: DtOsgObserverObject.h:1552
static const double theMinViewResolution
Definition: DtOsgObserverObject.h:1158
Angle
Definition: DtOsgObserverObject.h:1333
MotionState myAbsoluteRotatingState
Definition: DtOsgObserverObject.h:1401
osg::Vec3d myObserverRotationalVelocityVector
Definition: DtOsgObserverObject.h:1189
unsigned long long DtUniqueID
Definition: DtUniqueID.h:19
osg::Vec3d myPreviousTerrainCenter
Definition: DtOsgObserverObject.h:1555
bool myMutableHaveDownIntersect
Definition: DtOsgObserverObject.h:1524
bool myForceOrientReset
Definition: DtOsgObserverObject.h:1509
void stop()
Definition: DtOsgObserverObject.h:1301
The DtCoordinateSystem is used to manage the current coordinate system of the scene.
Definition: DtCoordinateSystem.h:40
bool myOrientCameraToTargetConstraint
Definition: DtOsgObserverObject.h:1504
osg::Vec3d myObserverFront
Definition: DtOsgObserverObject.h:1457
osg::Vec3d myObserverWorldNorth
Definition: DtOsgObserverObject.h:1449
MotionState myLevelObserverState
Definition: DtOsgObserverObject.h:1395
bool myLookingTiltRight
Definition: DtOsgObserverObject.h:1432
osg::Vec3d myObserverOffsetVector
Current offset from an attachment, when attached.
Definition: DtOsgObserverObject.h:1195
double myLastTickTime
Definition: DtOsgObserverObject.h:1177
osg::Vec3d myPreviousPositionVector
for backing out if we hit a constraint
Definition: DtOsgObserverObject.h:1533
void clearAdvance()
Definition: DtOsgObserverObject.h:1308
bool moving(Direction d) const
Definition: DtOsgObserverObject.h:1323
osg::Vec3d myEuler
Definition: DtOsgObserverObject.h:1389
osg::Quat myCameraShakeRot
Definition: DtOsgObserverObject.h:1569
osg::Quat myFlashlightRotation
Flashlight orientation offset as a quaternion.
Definition: DtOsgObserverObject.h:1231
Base class to provide boost signal/slot management.
osg::Vec3d myViewIntersect
Definition: DtOsgObserverObject.h:1522
osg::Quat my2DTo3DCachedObserverRotation
Definition: DtOsgObserverObject.h:1249
osg::Vec3d myLevelObserverMimicRight
Definition: DtOsgObserverObject.h:1474
bool mySyncPending
Definition: DtOsgObserverObject.h:1186
osg::Vec3d myAdvance
This, when scaled, will provide the direction that the observer should move in as the result of tick-...
Definition: DtOsgObserverObject.h:1388
bool myLookingRight
-— Camera
Definition: DtOsgObserverObject.h:1428
osg::Vec3d myAttachedUp
Definition: DtOsgObserverObject.h:1464
DT_DLL_vrfutil double mag(double x[3])
osg::Vec3d myCameraOffset
This is the camera offset wrt to observer.
Definition: DtOsgObserverObject.h:1444
osg::Quat mySavedObserverRotation
This is used for switching between track mode and other attach modes.
Definition: DtOsgObserverObject.h:1234
A DtSceneObject represents an object that can be positioned in the scene by (possibly) attaching it t...
Definition: DtSceneObject.h:44
osg::Vec3d myLevelAttachedRight
Definition: DtOsgObserverObject.h:1470
double myRotationSpeed
Definition: DtOsgObserverObject.h:1413
double myLastAttachedBvolDiameter
Definition: DtOsgObserverObject.h:1529
bool mySyncSuppressed
Definition: DtOsgObserverObject.h:1187
void setMoving(Direction d, bool moving)
Definition: DtOsgObserverObject.h:1328
double myMinLinearSpeed
Definition: DtOsgObserverObject.h:1417
osg::Quat myObserverRotation
This is our ENU observer orientation as a quaternion.
Definition: DtOsgObserverObject.h:1227
double myAttachedPitch
Definition: DtOsgObserverObject.h:1173
Contains DLL export macros.
double myLastAttachBvolOffset
Definition: DtOsgObserverObject.h:1530
MotionState myObserverState
Definition: DtOsgObserverObject.h:1394
osg::Vec3d myObserverLinearVelocityVector
Definition: DtOsgObserverObject.h:1188
float myLocalModelScalingAmount
Definition: DtOsgObserverObject.h:1192
osg::Vec3d myAttachedWorldUp
Definition: DtOsgObserverObject.h:1452
bool stopped()
Definition: DtOsgObserverObject.h:1313
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:76
std::vector< DtUniqueID > mySecondaryAttachments
Definition: DtOsgObserverObject.h:1169
osg::Vec3d myAttachPosition
Definition: DtOsgObserverObject.h:1527
A utility Quaternion class.
Definition: DtQuat.h:19
osg::Vec3d myOrientToPosition
Definition: DtOsgObserverObject.h:1213
bool myOrbitingRight
Definition: DtOsgObserverObject.h:1407
double myLastViewMagnification
Definition: DtOsgObserverObject.h:1545
osg::Vec3d myAttachedPosition
Definition: DtOsgObserverObject.h:1206
double myOrbitSpeed
Definition: DtOsgObserverObject.h:1411
static const double theMaxViewResolution
Definition: DtOsgObserverObject.h:1161
MotionState myLevelAttachedObserverState
Definition: DtOsgObserverObject.h:1397
DtModelSetId
Definition: DtModelSetEnums.h:19
bool myConstrainToTerrain
Definition: DtOsgObserverObject.h:1491
bool myUsesBoundingVolumeForAttachedOffsets
Whether or not the observer is using bounding volumes for attached offsets. This is all the time for ...
Definition: DtOsgObserverObject.h:1517
double myCurrentViewMagnification
Only used in 3D.
Definition: DtOsgObserverObject.h:1544
osg::Vec3d myObserverRight
Definition: DtOsgObserverObject.h:1458
bool myOrbiting
Definition: DtOsgObserverObject.h:1506
osg::Vec3d myCameraFront
Definition: DtOsgObserverObject.h:1481
bool myLookingDown
Definition: DtOsgObserverObject.h:1431
This abstract base class defines the interface for OS-specific keyboard and mouse event listeners...
Definition: DtOsgObserverObject.h:49
osg::Vec3d myLevelObserverPosition
Gravity change in observer position this frame.
Definition: DtOsgObserverObject.h:1204
double myCurrentObserverDistance
largest of the distances currently in play in a given frame. This is how far we&#39;ll advance...
Definition: DtOsgObserverObject.h:1221
double mySpeedScaleSpeed
Definition: DtOsgObserverObject.h:1419
static const double theObserverBoundingSphere
Definition: DtOsgObserverObject.h:1149
osg::Vec3d myAttachedRight
Definition: DtOsgObserverObject.h:1466
osg::Vec3d & euler()
Definition: DtOsgObserverObject.h:1358
AttachType
Definition: DtObserverObject.h:42
MotionState()
Definition: DtOsgObserverObject.h:1279

Document ID: Generated on Thu Oct 15 21:27:02 EDT 2026 from SVN revision 296421
Copyright © 2005-2026 MAK Technologies. All Rights Reserved (www.mak.com)