通过点击桌面来控制小地图的放大与缩小 let minMapTool = viewer.getExtension("Autodesk.AEC.Minimap3DExtension").tool document.onclick = function(e){ let targetZoomLevel = minMapTool.parent.targetZoomLevel; //每次缩放等级+0.1 let zoomLevelNew = targetZoomLevel +=0.1; var zoomLevelMax = minMapTool.parent.getMaxZoomLevel(); var zoomLevelMin = minMapTool.parent.getMinZoomLevel(); zoomLevelNew = THREE.Math.clamp(zoomLevelNew, zoomLevelMin, zoomLevelMax); minMapTool.parent.setZoomLevel(zoomLevelNew, false); }
通过点击桌面来控制小地图的放大与缩小