1

I want to use L.imageOverlay to show global temperature, my current image looks like the one below:

enter image description here

But when i overlay it using leaflet it shows like this:

enter image description here

Maybe it because wrong projection, this is my code:

L.imageOverlay('./tt.png',
    [[90, -180], [90, 180], [-90, 180], [-90, -180]],
    {opacity: 0.5, autoZIndex: true,interactive: true}
).addTo(map);

I think the problem is the conversion from Equirectangular to Mercator square projection, but i don't know how to fix that.

Daniel F
  • 13,684
  • 11
  • 87
  • 116
Duy Thức
  • 11
  • 2

0 Answers0