Showing floor picker in google maps api for javascript

后端 未结 1 1963
轮回少年
轮回少年 2021-02-09 15:58

When using the Google Maps API for android or ios it seems that the indoor maps are enabled by default and the \"floor picker\" control automatically appears when you zoom in to

相关标签:
1条回答
  • 2021-02-09 16:38

    Google doesn't support this in the Javascript API currently.

    These three issues all have responses from Google stating that it's an "Enhancement", which may mean they'll add it sometime:
    https://code.google.com/p/gmaps-api-issues/issues/detail?id=6642
    https://code.google.com/p/gmaps-api-issues/issues/detail?id=6792
    https://code.google.com/p/gmaps-api-issues/issues/detail?id=6783

    The only workaround I'm aware of is to manually add your own floor picker, then add each floor as an ImageMapType and switch between them. Unfortunately, this requires you to provide all of the floor imagery yourself rather than use Google's.

    ImageMapType docs: https://developers.google.com/maps/documentation/javascript/examples/maptype-image-overlay

    0 讨论(0)
提交回复
热议问题