<el-row><el-col :span="9">视角模式</el-col><el-col :span="15"> <el-select size="mini" v-model="detail.visualAngle" placeholder="请选择视角模式" @change="onChange"> <el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value"> </el-option> </el-select> </el-col></el-row>
handleFlyRoamInputChange(detail,data){ const { visualAngle, visualClearance, visualHeight } = detail let camera = { type: "", followedX: Number(visualClearance), followedZ: Number(visualHeight) } switch (visualAngle){ case '': camera.type = "" camera.followedX = undefined camera.followedZ = undefined break; case 'zdy': camera.type = "zdy" camera.followedZ = undefined break; case 'gs': camera.type = "gs" camera.followedX = undefined camera.followedZ = undefined break; case 'dy': camera.type = "dy" break; case 'sd': camera.type = "sd" camera.followedX = undefined break; } window.flyLine && window.flyLine.updateStyle({camera}); },
key: "updateAngle", value: function updateAngle(isAuto, opts) { if (isAuto) { this.entity.orientation = this.velocityOrientation; //基于移动位置自动计算方位 this._heading = null; this._pitch = null; this._roll = null; } else { opts = opts || {}; var position = this.position; //当前点 var _orientation = this.orientation; //获取当前角度 if (!position || !_orientation) return null; var autoHpr = (0, _matrix.getHeadingPitchRollByOrientation)(position, _orientation, this.viewer.scene.globe.ellipsoid, this._fixedFrameTransform); //重新赋值新角度 var heading = autoHpr.heading; var pitch = Cesium.Math.toRadians(Number(opts.pitch || 0.0)); var roll = Cesium.Math.toRadians(Number(opts.roll || 0.0)); this._heading = heading; this._pitch = pitch; this._roll = roll; this.entity.orientation = Cesium.Transforms.headingPitchRollQuaternion(position, new Cesium.HeadingPitchRoll(heading, pitch, roll), this.viewer.scene.globe.ellipsoid, this._fixedFrameTransform); }
{ key: "updateStyle", value: function updateStyle(params) { if (!this.options) return; for (var i in params) { if (_typeof(params[i]) === "object" && this.options[i]) { for (var key2 in params[i]) { this.options[i][key2] = params[i][key2]; } } else { this.options[i] = params[i]; } } }
createPath
lookAtTransform:控制朝向
viewer.scene.preUpdate.addEventListener:https://www.freesion.com/article/57661009683/
_this._fixedFrameTransform = Cesium.defaultValue(options.fixedFrameTransform, Cesium.Transforms.eastNorthUpToFixedFrame); //参考系
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· 记一次.NET内存居高不下排查解决与启示
· 探究高空视频全景AR技术的实现原理
· 理解Rust引用及其生命周期标识(上)
· 浏览器原生「磁吸」效果!Anchor Positioning 锚点定位神器解析
· 没有源码,如何修改代码逻辑?
· 分享4款.NET开源、免费、实用的商城系统
· 全程不用写代码,我用AI程序员写了一个飞机大战
· MongoDB 8.0这个新功能碉堡了,比商业数据库还牛
· 白话解读 Dapr 1.15:你的「微服务管家」又秀新绝活了
· 上周热点回顾(2.24-3.2)
2020-12-03 JavaScript如何保存全局变量(或中间变量)?
2020-12-03 基于OpenLayers和ArcGIS Server REST的要素属性信息查询和列表显示功能
2019-12-03 Model-Agnostic Meta-Learning for Fast Adaptation of Deep Networks(用于深度网络快速适应的元学习)
2018-12-03 图像中提取边缘线(轮廓)(等高线)