-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Exposing MGLGeometry_Private.h C++ globals #9819
Comments
We have no plans to expose any C++ interfaces as part of the iOS or macOS SDK’s public API, because it would break applications written in pure Objective-C or Swift. That said, if there are opportunities to implement these conversions independently in Objective-C, there might be a viable path to adding such an implementation to the public API. |
Yes that is the approach(tile covertion done seperately at my swift/js client side) I actually followed in the end. |
But if it will be available in SDK out of the box that would be certainly helpful. |
@1ec5: does it make sense for me to go with a pull request to js/ios sdks? |
Yes, we’d be open to a PR for the iOS and macOS SDKs at least. MGLComputedShapeSource (#6940 #9983) introduced x/y/z tile coordinates as a concept. For that feature, we ultimately went with a series of method parameters (e.g.,
On second thought, C++ is only a concern because these methods are currently inlined. If we move the implementations of these methods to a .mm file – probably a good idea anyways – then they’d be perfectly compatible with pure Objective-C. |
Hi guys,
It would be great to have tile geometry available to a client for feature reconstitution discussed in #9647, so I have exposed tile geometry with:
in
MGLGeometry_Private.h
, whileMGLTileID
is defined as:It does work for me when I wrap these functions inside Objective-C++ methods, however I am hitting linker failures when I try exposing them directly as
in
MGLGeometry.h
.(ref: GeoThings@2d6d23b)
It feels like I am missing something obvious that I don't know here, any thoughts guys?
The text was updated successfully, but these errors were encountered: