You are here

function legacy_gmap_polyutil_encode_latlon in GMap Module 7.2

Encode latlon function.

1 call to legacy_gmap_polyutil_encode_latlon()
legacy_gmap_polyutil_polyline in tests/inc/gmap_polyutil.inc
Simplify a set of points and generate an "Encoded Polyline" for Google Maps.

File

tests/inc/gmap_polyutil.inc, line 36
Encoded polyline utilities.

Namespace

tests\inc

Code

function legacy_gmap_polyutil_encode_latlon($x) {
  $x = round($x * 100000.0) << 1;
  if ($x < 0) {
    $x = ~$x;
  }
  return legacy__gmap_polyutil_encode($x);
}