Overlay drawing on the wrong spot

61 Views Asked by At

I've asked a similar question before, I know. But this is a bit different.

Here's this image: The screenshot

Now, you see the custom marker is being drawn slightly to the right of the original geopoint. I tried experimenting with the location but couldn't get it fixed.

The pin is a custom image that was created in photoshop. Are there any particular guidelines that need to be followed? I'm confused. It was drawing way off before, so I used the following line of code (in the CustomOverlay constructor) to move it closer, but its still off:

defaultMarker.setBounds(0, -defaultMarker.getIntrinsicHeight(), defaultMarker.getIntrinsicWidth(), 0);
0

There are 0 best solutions below