MapVGL实现3D柱形条——数据可视化1

时间:2025-03-31 07:51:41
let keyFrames = [ // 定义关键帧 { center: new BMapGL.Point(113.828642, 23.741507), zoom: 2, tilt: 80, heading: 0, percentage: 0 }, { center: new BMapGL.Point(113.828642, 23.741507), zoom: 2, tilt: 80, heading: 36, percentage: 0.1 }, { center: new BMapGL.Point(113.828642, 23.741507), zoom: 2, tilt: 80, heading: 72, percentage: 0.2 }, { center: new BMapGL.Point(113.828642, 23.741507), zoom: 2, tilt: 80, heading: 108, percentage: 0.3 }, { center: new BMapGL.Point(113.828642, 23.741507), zoom: 2, tilt: 80, heading: 144, percentage: 0.4 }, { center: new BMapGL.Point(113.828642, 23.741507), zoom: 2, tilt: 80, heading: 180, percentage: 0.5 }, { center: new BMapGL.Point(113.828642, 23.741507), zoom: 2, tilt: 80, heading: 216, percentage: 0.6 }, { center: new BMapGL.Point(113.828642, 23.741507), zoom: 2, tilt: 80, heading: 252, percentage: 0.7 }, { center: new BMapGL.Point(113.828642, 23.741507), zoom: 2, tilt: 80, heading: 288, percentage: 0.8 }, { center: new BMapGL.Point(113.828642, 23.741507), zoom: 2, tilt: 80, heading: 324, percentage: 0.9 }, { center: new BMapGL.Point(113.828642, 23.741507), zoom: 2, tilt: 80, heading: 360, percentage: 1 }, ]; let opts = { duration: 15000, // 花费时间 delay: 20, // 延迟 interation: 'INFINITE' // 循环, 可设置数字为次数 }; let animation = new BMapGL.ViewAnimation(keyFrames, opts); // 创建视角动画 this.map.startViewAnimation(animation); // 开始动画