forked from Scottish-Tech-Army/Soundscape-Android
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix coordinate system used within FMOD to preserve direction
Prior to this change the code was just using longitude and latitude as x,y coordinates within FMOD. That's fine near the equator where 1 degree is a similar distance in each direction, but moving away from the equator 1 degree of latitude shrinks (down to zero at the poles!). This change uses a very simple equirectangular projection to translate longitude and latitude into an x,y system for FMOD. The origin used is the first coordinate converted which will be either the current location, or the locatoin of a beacon. Ensuring that the origin is relatively close means that the projection is accurate enough for our purposes. To test the improvement, create an audio beacon and point directly at it on the UI map. The audio should be playing evenly out of left and right on your headphones.
- Loading branch information
Showing
4 changed files
with
64 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters