GoogleMaps Framework Reference

GMSGeometryIsLocationOnPathTolerance

extern BOOL GMSGeometryIsLocationOnPathTolerance(CLLocationCoordinate2D point,
                                                 GMSPath *_Nonnull path,
                                                 BOOL geodesic,
                                                 CLLocationDistance tolerance)

Returns whether point lies on or near path, within the specified tolerance in meters. path is composed of great circle segments if geodesic is YES, and of rhumb (loxodromic) segments if geodesic is NO.

See also GMSGeometryIsLocationOnPath(point, path, geodesic).

The tolerance, in meters, is relative to the spherical radius of the Earth. If you need to work on a sphere of different radius, you may compute the equivalent tolerance from the desired tolerance on the sphere of radius R: tolerance = toleranceR * (RadiusEarth / R), with RadiusEarth==6371009.