ThinkGeo.com    |     Documentation    |     Premium Support

Projection with 3857

Hi @Ethan, I’m getting some weird behavior of the map. when applying EPSG:3857 to shape file projection but working correctly ESRI:54004 . Just Check the sample also after adding graticule that custom polyshape is changing.

For EPSG:3857 add graticule also and check it.

9229.zip (179.7 KB)

Hi Bibek,

Do you means the “tolerance condition error” appear when 54004, but not for 3857?

If that’s the problem you mentioned, please wait our research and fix.

If you means other issue please let us know.

Regards,

Ethan

Actually when i’m adding 3857 projection all the polygons and graticule getting some weird spikes

Hi Bibek,

Projection don’t support multiply threading, but the overlays refresh multiply threading.

So please change your code follow our sample:

9229.zip (179.1 KB)

You can add all the layers into the same overlay to avoid this problem, or assign different projection instance for all layers in each overlay.

Regards,

Ethan

hey @Ethan, What is the advantage if i do like this instead of Creating one projection object and use that in all places?

Hi Bibek,

It can solve the strange looks problem you mentioned.

Regards,

Ethan

Hi , Can You give me a example where i can use projection object with different overlays ? also, I can use projection object to convert to external projection. I have 50 overlays so i have to create 50 projection object , cause as your’s statement projection not support multiple threading .

Hi Bibek,

You just need to create new instance of Proj4Projection for different overlay, I think you can build a simple function to get it. Don’t worry about 50 object, when the Proj4Projection is not using, it don’t take much source, if it can solve the issue we can ignore the number of it.

Regards,

Ethan