Skip to content

Instantly share code, notes, and snippets.

@mousebird
Created March 10, 2016 21:54
Show Gist options
  • Save mousebird/6335ce73f789344eeca5 to your computer and use it in GitHub Desktop.
Save mousebird/6335ce73f789344eeca5 to your computer and use it in GitHub Desktop.
Custom British National Grid projection
let proj4Str = "+proj=tmerc +lat_0=49 +lon_0=-2 +k=0.9996012717 +x_0=400000 +y_0=-100000 +ellps=airy +units=m +no_defs"
let coordSys = MaplyProj4CoordSystem(string: proj4Str)
var bbox = MaplyBoundingBox()
bbox.ll.x = 1393.0196
bbox.ll.y = 12494.9764
bbox.ur.x = 671196.3657
bbox.ur.y = 1230275.0454
coordSys.setBounds(bbox)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment