You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
thank you for the lib! There is a little problem with the levels. I wanted to have a shorter token to be generated per cell. I'm storing the tokens in a highly optimized and compressed DB. Every byte counts. Therefore lower level for "encoding" is desired for having shorter token based on lower subdivision precision.
This would be possible with e.g.:
S2.MAX_LEVEL = 10
S2CellId.MAX_LEVEL = 10
However, there is the S2Cell which has private static MAX_CELL_SIZE that defines:
MAX_CELL_SIZE = 1 << S2CellId.MAX_LEVEL;
I can't change this because it's private static and therefore all subsequent calculations fail.
I'd like to do:
S2Cell.MAX_CELL_SIZE = 1 << S2CellId.MAX_LEVEL;
And have a Utils helper method for setting so; I'd PR - but this repo seems unmaintained? :)
Hello @kyr0, although i'd like to keep this repo as equal to the google's implementation if there is a real reason and use-case where this could help i am not against it as long as it's documented in the READMe section.
As per the "unmaintained" yes, it was at least. It seems the library gained traction recently (unknown reasons to me) and therefore i will maintain it to the best of my free-time and capabilities for those who encounter bugs and stuff.
That being said, if you'd like to provide a merge request. I'll be more than happy to review it and merge it.
Hi,
thank you for the lib! There is a little problem with the levels. I wanted to have a shorter token to be generated per cell. I'm storing the tokens in a highly optimized and compressed DB. Every byte counts. Therefore lower level for "encoding" is desired for having shorter token based on lower subdivision precision.
This would be possible with e.g.:
S2.MAX_LEVEL = 10
S2CellId.MAX_LEVEL = 10
However, there is the S2Cell which has private static MAX_CELL_SIZE that defines:
MAX_CELL_SIZE = 1 << S2CellId.MAX_LEVEL;
I can't change this because it's private static and therefore all subsequent calculations fail.
I'd like to do:
S2Cell.MAX_CELL_SIZE = 1 << S2CellId.MAX_LEVEL;
And have a Utils helper method for setting so; I'd PR - but this repo seems unmaintained? :)
@vekexasia @rh389 @andrezsanchez ?
The text was updated successfully, but these errors were encountered: