BhavikKama
BhavikKama

Reputation: 8790

How to show user location on custom map?

I want to show user location and other object location on custom map as follows :

For that I have Googled the things that says "we need to convert the lat long data in to X Y Coordinates in the image and then we need to show it on image"

Other option I found is geocode the image to show the location data.

I didn't find anything else other than this. Can anyone please guide me to show user current location on the custom map as follows?

Upvotes: 0

Views: 309

Answers (1)

Azat
Azat

Reputation: 6795

For translating your lattitude and longitute you should know the projection of your custom map. Then you can use PROJ.4 open source library to convert them. Or you can hardcode translation function to you app. For example, here at GitHub you may found code to translate from lat&lon to EPSG:900913 (google mercator projection)

Upvotes: 1

Related Questions