Skip to content
This repository has been archived by the owner on Aug 8, 2023. It is now read-only.

Add light property to MGLStyle #8840

Closed
1ec5 opened this issue Apr 27, 2017 · 4 comments
Closed

Add light property to MGLStyle #8840

1ec5 opened this issue Apr 27, 2017 · 4 comments
Assignees
Labels
beta blocker Blocks the next beta release GL JS parity For feature parity with Mapbox GL JS iOS Mapbox Maps SDK for iOS macOS Mapbox Maps SDK for macOS runtime styling
Milestone

Comments

@1ec5
Copy link
Contributor

1ec5 commented Apr 27, 2017

Per #8431 (comment), MGLStyle needs a light property that lets the developer set style-wide parameters like lighting color and intensity. We’ll need an MGLLight class to hold these individual properties. Hopefully we can make MGLLight consistent with SceneKit’s SCNLight and the style specification simultaneously.

One complication is that mbgl::Map::setLight() takes a std::unique_ptr instead of an mbgl::style::Light object by value (which is how mbgl::CameraOptions and mbgl::AnimationOptions work). Developers will expect MGLLight to be a value class along the lines of MGLMapCamera.

/cc @fabian-guerra @lbud @jfirebaugh

@1ec5 1ec5 added GL JS parity For feature parity with Mapbox GL JS iOS Mapbox Maps SDK for iOS macOS Mapbox Maps SDK for macOS runtime styling labels Apr 27, 2017
@1ec5 1ec5 added this to the ios-v3.6.0 milestone Apr 27, 2017
This was referenced Apr 27, 2017
@fabian-guerra fabian-guerra self-assigned this May 1, 2017
@ivovandongen
Copy link
Contributor

@fabian-guerra FYI I'm making some slight adjustments to the light API in #8889.

@1ec5
Copy link
Contributor Author

1ec5 commented May 4, 2017

#8889 moves mbgl’s Light interface to codegen, which suggests that we should probably use codegen to build MGLLight.h and MGLLight.mm as well.

@1ec5 1ec5 added the beta blocker Blocks the next beta release label May 8, 2017
@1ec5
Copy link
Contributor Author

1ec5 commented May 9, 2017

#8841 is the corresponding Android issue.

@1ec5
Copy link
Contributor Author

1ec5 commented May 23, 2017

Fixed in #9043 on the release-ios-v3.6.0-android-v5.1.0 branch.

@1ec5 1ec5 closed this as completed May 23, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
beta blocker Blocks the next beta release GL JS parity For feature parity with Mapbox GL JS iOS Mapbox Maps SDK for iOS macOS Mapbox Maps SDK for macOS runtime styling
Projects
None yet
Development

No branches or pull requests

4 participants