MakieOrg/Tyler.jl

Use figure resulution to choose zoom level

rafaqz opened this issue · 4 comments

Higher resolution figures should have more tiles, but currently the resolution has no effect and large plots appear a little pixelated.

Ah, I guess we must have removed that... In my initial prototype we did use the resolution!

visr commented

MapTiles has this function for determining the resolution which can be used:
https://github.com/JuliaGeo/MapTiles.jl/blob/a2c818a921bb1737ff54537aace7e4f57fde2194/src/tiles.jl#L10

It's actually the opposite function we need- getting the z from extent and resolution. I've written a function for that in MapTiles.jl.

@SimonDanisch how do we get the resolution of a figure?

@rafaqz
if I do
fig = lines(1:10)

then

fig.figure.scene.theme.resolution.val

would output the figure's resolution.