1

On small mobile screens, I'd like to display 384x384 "retina" tiles instead of 256x256, but also with the viewport scaled 1.5x.

Tile size handling with pixelRatio:1.5 works well, however the actual size on screen is the same. Also, if I set

map.getViewport().style.transform="scale(1.5)";

Then the viewport is scaled, but tiles looks pixelized even if they are 384x384. I'm looking for a magnifier here, magnifier that should display well with 384x384 tiles.

1

Ah, something like this may do the trick:

map.getViewport().getElementsByTagName('canvas')[0].getContext("2d").scale(1.5,1.5);

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.