Ok for 1) I looked it up (thanks U SAVED ME TREMENDOUS CALCULATIONS) but the function: float res = distanceTo(loc); that takes loc which is a location is not recognized. Is it deprecated or somethign?
for 2) do you have any working sample? thnaks a lot! On Jun 5, 11:14 am, Brian Smith <[email protected]> wrote: > It's still a 2-step process, using classes from 2 completely different > packages. > > 1) android.location.Location to compute distance and angle from start > to end point... unless you want to implement the math yourself > > 2) SensorManager and SensorListener (in android.hardware) to determine > current orientation of phone > > You will also want to use android.hardware.GeomagneticField to find > the magnetic declination for the user's current location (or at least > a point that's close to it). The orientation sensor uses magnetic > north, as far as I know, and I believe the math in Location probably > uses true north. The difference can be a lot or a little depending on > where you are. > > On Jun 5, 11:02 am, Georgy <[email protected]> wrote: > > > yeah I need to bring up the compass to tell the user where EXACTLY is > > the destination when the user is close. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---

