禁用StreetView导航到未连接的photospheres

问题描述 投票:-2回答:2

由于StreetVew没有层次(楼层),我在多层次旅游中面临着巨大的问题,因为导航从一层跳到另一层(实际上这两个层板实际上非常接近,但在不同楼层,并没有直接连接)。我想通过禁用两种导航方法中的一种可以解决问题,我只是在API中找不到它。我使用以下代码通过MAPS API嵌入photospheres:

google.maps.event.addDomListener(window, 'load', initialize);
function initialize() {
  google.maps.streetViewViewer = 'photosphere';
  var panorama = new google.maps.StreetViewPanorama(
    document.getElementById('pano'), {
      pano: 'PANOID',
      pov: {heading: 348.27, pitch: -1.62, zoom: 0.26},
      linksControl: true,
      zoomControl: true,
      zoomControlOptions: {
        style: google.maps.ZoomControlStyle.SMALL,
        position: google.maps.ControlPosition.RIGHT_TOP
      },
      scaleControl: false,
      overviewMapControl: false,
      panControl: false,
      visible: true,
      motionTracking: false,
      motionTrackingControl: false
  });
}

有什么选项可以禁用屏幕截图中的右箭头(箭头周围有一个圆圈),如果它存在的话?

screenshot

google-maps-api-3 google-street-view
2个回答
1
投票

该选项称为“clickToGo”,应设置为false。

我搜索它并找不到,所以我决定通过所有的选项和实验,并碰到它...


1
投票

确实将clickToGo设置为false以禁用甜甜圈。

除此之外,Streetview支持楼层,因为当您发布全景图时,您拥有以下属性:

pose.heading
pose.latLngPair
pose.pitch
pose.roll
pose.level
pose.altitude
connections
places

cf:https://developers.google.com/streetview/publish/reference/rest/v1/photo/update

多个例子:https://goo.gl/maps/nDvPsbDakLN2

© www.soinside.com 2019 - 2024. All rights reserved.