Refactor: use conversion system to convert MGLStyleFunction to mbgl core types (#8026)
This leverages the work already happening in `mbgl::style::conversion` to convert style functions from style-spec definitions into `mbgl::style::{Camera,Source,Composite}Function`s. In particular, this allows the conversions system to handle the differing typing requirements based on whether the output type of the style function is interpolatable or non-interpolatable.
This commit is contained in:
@@ -200,7 +200,7 @@ struct Converter<CameraFunction<T>> {
|
||||
|
||||
template <class T, class V>
|
||||
Result<optional<T>> convertDefaultValue(const V& value) {
|
||||
auto defaultValueValue = objectMember(value, "defaultValue");
|
||||
auto defaultValueValue = objectMember(value, "default");
|
||||
if (!defaultValueValue) {
|
||||
return {};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user