Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

153
Views
Get geospatial coordinates a path projected with D3.js

I have successfully project an SVG world map and some other shapes onto a sphere using D3.js.

I can easily map points to the sphere, but I don't yet have the other way around. From a mouse event, I'd like to derive the lat/lng or just the general angles at the pointer.

Before I go down the math rabbit hole, is there something built into D3.js to handle the inverted mapping? Or an existing solution otherwise?

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Assuming you are using this library, you could try the invert() method

For newer versions, as of v6 at least:

//in click or other mouse event handler
const coords = projection.invert(d3.pointer(event, this));
about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!