Spyke

Syndicated from the fediverse. Read and engage on the original instance.

View original on thelemmy.club
nostupidquestions·No Stupid QuestionsbyHobbitFoot

What is the easiest way to convert latitude and longitude to a point on a jpeg map?

I want to create an image showing the location of something and I know the GPS coordinates. What's the easiest workflow to show the location of those coordinates on a map?

Edit: I don't have a map image chosen yet.

View original on thelemmy.club
23

15 replies

If you use a plate carrée projection (in which all lines of latitude and longitude are rectangular and equal), it’s a simple linear formula:

x = (longitude + 180) * (map width / 360)
y = (-latitude + 90) * (map height / 180)

(Assuming west and south coordinates are negative, and all degrees are expressed as decimals.)

16

You need to know the map projection and coordinate system...

After you know all that, you can use some math to convert.

7
sh.itjust.works

With the Mercator projection this would be pretty easy. As your projections get more wild so will the math.

1

Op didn't specify Mercator projection.... If referring to paper maps scanned or something similar, everything might be. Maybe UTM maybe worse

1
lemmy.ml

Can you enter them into open street maps or google maps and take a screenshot?

4

I'm going to have to look at that, that seems to be the closest to what I'm looking for. Thanks.

3

If you're ok zooming out far enough you can serve a static image of the pale blue dot and a red arrow pointing to it.

3

Type the coordinates into Google maps to find the location.

Then just make a dot on any other map in the same place.

1
lemmy.world

Isn't there like a convertor for this...not being rude but I had to do this a while back. Let me go and see if I can find it against. It would convert anything to any size. How big is your jpeg map btw?

1

You reached the end

What is the easiest way to convert latitude and longitude to a point on a jpeg map? | Spyke