Android Question GPS BearingTo

Harris

Expert
Licensed User
Longtime User
bearingto.jpg


Here we have a GPS Point (red box) (lat, lon) that is close to us (stored in a table). This is determined by a lookup to see which (GPS) points are close.

This marker is also restricted to a var which determines "meters away from current position" (ie. 100 meters). If within - include - else discard

When moving in a direction (in this example - from east to west), I need to know if a defined GPS point is within the current viewport - which is within, let's say, 30 degrees from the direction I am travelling - bearing to.

This example shows it is outside my current view. However, should I turn North towards the point, it will be in my view.

How can I use Bearingto (and associated funcs) to determine this?
I have tried yet I can't figure out the logic...

Thanks
 
Top