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

Add support for configurable pixel sizes #851

Merged
merged 2 commits into from
Jun 1, 2016
Merged

Conversation

rmarianski
Copy link
Member

Connects to #810

Included in this pr is a system to assign classes to features. Based on earlier conversations, I assume that we want to expose these properties in the tiles themselves. If we don't, we should rename to mz_class and they will get dropped. I also just made them integers for now; but they can be changed to whatever is easier to work with. Something else to consider is that the word class might not be the smartest choice because it's a keyword in many languages. However, I tried it in a node.js repl and didn't seem to have any problems with it though.

The implementation here re-uses the csv machinery to specify and assign these properties. The idea is that the mz_min_pixels spreadsheets will define the rules for the configurable pixel sizes, and a transform is configured that drops any features with areas that don't meet this threshold. The transform assumes that the thresholds will be in pixel values, and calculates the required area for the feature based on the zoom level. Having the capability to assign class values could be useful to determine the pixel thresholds.

Note that there aren't any rules specified, but the pieces are in place to honor any subsequent changes.

@zerebubuth, @nvkelso could you review please?

@rmarianski rmarianski self-assigned this May 31, 2016
@rmarianski rmarianski added this to the v1.0.0 milestone May 31, 2016
@rmarianski rmarianski removed their assignment May 31, 2016
@zerebubuth
Copy link
Member

Looks good to me! 👍

@rmarianski rmarianski merged commit f7e5629 into master Jun 1, 2016
@rmarianski rmarianski deleted the configurable-pixel-size branch June 1, 2016 13:51
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

Successfully merging this pull request may close these issues.

2 participants