offset static method

List<double> offset(
  1. double lat,
  2. double lng, {
  3. double east = 0,
  4. double north = 0,
})

Offsets a coordinate by metres east / north, returning [lat, lng].

Implementation

static List<double> offset(double lat, double lng, {double east = 0, double north = 0}) => <double>[
  lat + north / earthRadius * 180 / pi,
  lng + east / (earthRadius * cos(_rad(lat))) * 180 / pi,
];