Select to view content in your preferred language

How to show  a compass on the map

3748
4
08-12-2013 05:53 AM
xinlongliu
Emerging Contributor
Hi:
  I am writing a program to show a compass on the map.When the android phone move,the compass will also move.I have the point which stand for the position of the device.I know the point class have a method PictureMarkerSymbol .How to show the compass on the point,and the compass-picutre is not big.
0 Kudos
4 Replies
ThomasBinu
Deactivated User
In our application, we have implemented a compass that rotates if the user rotates the map using the gesture. I have uploaded a sample project based on the esri compass sample. See below link
https://github.com/tmsbn/Esri-compass-sample.git
0 Kudos
xinlongliu
Emerging Contributor
In our application, we have implemented a compass that rotates if the user rotates the map using the gesture. I have uploaded a sample project based on the esri compass sample. See below link
https://github.com/tmsbn/Esri-compass-sample.git


the MapRotation?
0 Kudos
DanO_Neill
Deactivated User
We have a sample in the SDK which from the sounds of it does what you are asking for.  Have a look at it here.
0 Kudos
xinlongliu
Emerging Contributor
We have a sample in the SDK which from the sounds of it does what you are asking for.  Have a look at it here.


Thanks for your reply.I have achieved the compass.Firstly i set the point which stands for the phone-location on the map with a picture.The program received the angles from the Sensor and timely update the point use api "GraphicsLayer.updateGraphic(int id, Graphic graphic)".Just like this picture [ATTACH=CONFIG]27278[/ATTACH]
0 Kudos