title: How can I correctly convert geographical coordinates to pixels on screen?
body: <p>I'm trying to make a Java project that pinpoints the place on a image of a map, when given coordinates (taken from Google Maps). </p>
  
  <p>I've tried using the top-left corner of the image (place that has highest latitude, and the lowest longitude), as an some kind of an reference point, which would be (0,0) point on the map image, and than I've tried to calculate every place on the map based on that reference point. However, this method proved inaccurate, probably because of the curvature of the Earth (mind that the map I'm working with (Serbia) covers area of 4° latitude, and 4° longitude).</p>
  
  <p>I've seen couple of answers talking about converting into Mercator projection, but they are not very clear to me, because they are not covering a case similar to mine, and are not written in Java.</p>
  
  <p>What can I do to pinpoint those points more accurately (±3km would be accurate enough)?</p>