]> git.mxchange.org Git - simgear.git/blobdiff - simgear/sound/soundmgr_openal.hxx
make the relative positions fixed against the body again.
[simgear.git] / simgear / sound / soundmgr_openal.hxx
index c24afc57def722634f70787539f444579b6ca0a3..ecfd2637f87ed41adffa4f505afc4e713640a5bc 100644 (file)
@@ -153,11 +153,15 @@ public:
     SGSampleGroup *find( const string& refname, bool create = false );
 
     /**
-     * Set the Geodetic position of the sound manager.
+     * Set the Cartesian position of the sound manager.
      * @param pos OpenAL listener position
      */
     void set_position( const SGVec3d& pos ) {
-        _absolute_pos = pos; _changed = true;
+        _base_pos = pos; _changed = true;
+    }
+
+    void set_position_offset( const SGVec3d& pos ) {
+        _offset_pos = pos; _changed = true;
     }
 
     /**
@@ -281,6 +285,8 @@ private:
 
     // Position of the listener.
     SGVec3d _absolute_pos;
+    SGVec3d _offset_pos;
+    SGVec3d _base_pos;
 
     // Velocity of the listener.
     SGVec3f _velocity;