Latitude / Longitude Grid Lines (Graticule)

Hello all,

I have seen some discussion about this going back to 2014 and found the addon Graticule.js by Thomas Lefort. I wasn’t sure how well that works out of the box because it seems the live site it links to is broken. Anyway, I improved upon that (hopefully) for my own project and thought I would share the results in a sandcastle here.

I hope this is useful to anyone that needs this for their project.

Cheers!

1 Like

Looks awesome! Thank you for sharing.

We also have a an example in our Sandcastle repository that you can check out here.

This looks great! Would you consider making a quick repo for it somewhere, ideally including a license? I use GridImageryProvider today, but without labels on the lines they’re not nearly as useful.

1 Like

We put together an Apache Licensed fork of Graticule here, in Mapshot. Check it out!

1 Like

Here’s an updated link, fixed the issues at the poles:

Mapshot.app - Graticule Fork

Hi, this project is really nice!
I’ve tried my best to convert it to react (with resium), in this repo (Of course, with full credit given to the original author).

I’m still facing some performance issues, since the grid is being re-rendered with each movement of the globe. I hope to fix this issue in the future, but again, it looks awesome

Did you check out our fork above?
It should solve those performance issues.

This looks fantastic! Just one question: how could I make the graticule lines clamp to the ground? This version of grid lines seems to be blocked by the terrain. I looked for PolylineGraphics but it didn’t help me with that.