Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is it possible to define different height for each tile? #167

Open
amalamrani opened this issue Jul 21, 2023 · 1 comment
Open

Is it possible to define different height for each tile? #167

amalamrani opened this issue Jul 21, 2023 · 1 comment

Comments

@amalamrani
Copy link

To give less height to the tiles near the poles and more height to the tiles near the equator using tileHeight function?

the problem is when doing this:
tileWidth = 360 /total number of tiles;
tileHeight = 180 / total number of tiles;
.tileHeight( tileHeight - TILE_MARGIN );

all the tiles have the same height and therefore those closest to the equator appear very stretched.
any suggestion?

Thank you for sharing this library. It's very helpful
Regards.

@vasturiano
Copy link
Owner

@amalamrani the tileHeight can accept a tile accessor function. So you can do something like:

.tileHeight(tile => /* your code */)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants