flyTo
Navigate to specific geographic coordinates with animated camera transitions in 3D globe visualization.
Instructions
飞行到指定经纬度位置(带动画过渡)
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| longitude | Yes | 经度(-180 ~ 180) | |
| latitude | Yes | 纬度(-90 ~ 90) | |
| height | No | 相机高度(米),默认 50000 | |
| heading | No | 航向角(度),0 为正北 | |
| pitch | No | 俯仰角(度),-90 为正下方 | |
| duration | No | 飞行动画时长(秒) |
Implementation Reference
- The actual implementation of the flyTo functionality that manipulates the Cesium viewer camera.
export function flyTo(viewer: Cesium.Viewer, params: FlyToParams): Promise<void> { const { longitude, latitude, height = 50000, heading = 0, pitch = -45, roll = 0, duration = 2, } = params validateCoordinate(longitude, latitude, height) return new Promise((resolve) => { viewer.camera.flyTo({ destination: Cesium.Cartesian3.fromDegrees(longitude, latitude, height), orientation: { heading: Cesium.Math.toRadians(heading), pitch: Cesium.Math.toRadians(pitch), roll: Cesium.Math.toRadians(roll), }, duration, complete: resolve, }) }) } - packages/cesium-mcp-bridge/src/bridge.ts:89-91 (registration)The tool registration in the bridge class, which dispatches 'flyTo' actions.
case 'flyTo': await this.flyTo(p as FlyToParams) return { success: true, message: 'Camera flew to target position' }