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

Drive paint attribute binding logic off the style spec #3525

Closed
jfirebaugh opened this issue Nov 3, 2016 · 0 comments · Fixed by #3527
Closed

Drive paint attribute binding logic off the style spec #3525

jfirebaugh opened this issue Nov 3, 2016 · 0 comments · Fixed by #3527
Assignees

Comments

@jfirebaugh
Copy link
Contributor

jfirebaugh commented Nov 3, 2016

I'd like to see declarations like this replaced with:

paintProperties: ['circle-color', 'circle-radius', 'circle-blur', 'circle-opacity']

And ideally, even the list of data-driven properties would itself be derived from the style spec.

The logic for how to bind a paint property to an attribute or uniform can be driven by style specification properties, and dependent not on the individual property but on its type. All color properties are bound the same way. Numeric properties with a spec-defined minimum and maximum can derive an integer size and multiplier from that range. Numeric properties where the minimum or maximum value is not defined should probably just use a float attribute, to avoid issues like #3464.

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

Successfully merging a pull request may close this issue.

2 participants