Skip to content

allanragec/AMLocationBased-iOS

Repository files navigation

Welcome to the AMLocationBased-iOS wiki!

Installing from CocoaPods pod 'AMLocationBased'

Can be used with Google Maps too, and iOS 5 or more. The project will have two examples of use and the lib. The lib consists of only one class, UtilsTrigonometry, in them you will find several methods that can help in other tasks, among which the main ones are:

Method that tells how many degrees the other location is me, this way you can present another location in some way, maybe using a compass. It can be used to make augmented reality.

In the example, the starting point is always the red pin.

**+(double)getDegreesOfAnotherLocationWithMyLocation:(CLLocation )myLocation andAnotherLocation:(CLLocation )anotherLocation;

Creates a second location, from an existing, from the degree informed and the desired distance.

+(CLLocation)locationFromDistance:(double)distance andDegrees:(int)degrees withMyLocation:(CLLocation)myLocation;**