Compare commits
	
		
			3 Commits
		
	
	
		
			master
			...
			43a4fca804
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 43a4fca804 | |||
| 53e692f6ca | |||
| dd1855002f | 
| @ -22,53 +22,14 @@ class AssembleObject extends Base { | ||||
|    * @param sdk | ||||
|    * @description 集结地 | ||||
|    * @param options {object} 属性 | ||||
|    * @param options.id {string} 唯一标识 | ||||
|    * @param options.show=true {boolean} 显示/隐藏 | ||||
|    * @param options.name {string} 名称 | ||||
|    * @param options.color='rgba(255, 0, 0, 0.5)' {string} 颜色 | ||||
|    * @param options.color="#ff000080" {string} 颜色 | ||||
|    * @param options.height {number} 高度 | ||||
|    * @param options.heightMode=2{number} 高度模式(0:海拔高度;1:相对地表;2:依附模式) | ||||
|    * @param options.areaUnit='平方米' {string} 面积单位 | ||||
|    * @param options.line {object} 边框 | ||||
|    * @param options.line.width=2 {string} 边框宽 | ||||
|    * @param options.line.color="rgba(155, 155, 124, 0.89)" {string} 边框颜色 | ||||
|    * @param {Array.<object>} options.positions 必填,经纬度和高度的列表,值交替 [{lon,lat,alt},...] | ||||
|    * @param options.positions[].lng {number} 经度 | ||||
|    * @param options.positions[].lat {number} 纬度 | ||||
|    * @param options.positions[].alt {number} 高度 | ||||
|    * @param options.label {object} 标签对象 | ||||
|    * @param options.label.text {string} 标签文本 | ||||
|    * @param options.label.show {string} 标签显隐 | ||||
|    * @param options.label.position {string} 标签位置 | ||||
|    * @param options.label.position {object} 标签位置 | ||||
|    * @param options.label.position.lng {number} 经度 | ||||
|    * @param options.label.position.lat {number} 纬度 | ||||
|    * @param options.label.position.alt {number} 高度 | ||||
|    * @param options.label.fontSize=20 {number} 字体大小 | ||||
|    * @param options.label.fontFamily=0 {number} 字体项 0:黑体;1:思源黑体;2:庞门正道标题体;3:数黑体 | ||||
|    * @param options.label.color=#ffffff {string} 字体颜色 | ||||
|    * @param options.label.lineWidth=4 {number} 引线宽 | ||||
|    * @param options.label.lineColor=#00ffff80 {string} 引线颜色 | ||||
|    * @param options.label.pixelOffset=20 {number} 字体偏移(引线长度) | ||||
|    * @param options.label.backgroundColor=['#00ffff80', '#00ffff80'] {array} 背景颜色 | ||||
|    * @param options.label.scaleByDistance {boolean} 距离缩放 | ||||
|    * @param options.label.near=2000 {number} 视野缩放最近距离 | ||||
|    * @param options.label.far=100000 {number} 视野缩放最远距离 | ||||
|    * @param options.attribute {object} 属性内容 | ||||
|    * @param options.attribute.link={} {object} 链接 | ||||
|    * @param options.attribute.link.content=[]] {array} 链接内容 | ||||
|    * @param options.attribute.link.content[].name {string} 链接名称 | ||||
|    * @param options.attribute.link.content[].url {string} 链接地址 | ||||
|    * @param options.richTextContent {string} 富文本内容 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    * @param {Array.<object>} options.positions 坐标数组 [{lon,lat,alt},...] | ||||
|    * @param _Dialog {object} 弹框事件 | ||||
|    * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    * */ | ||||
|   constructor(sdk, options = {}, _Dialog = {}) { | ||||
|     super(sdk, options); | ||||
|  | ||||
| @ -22,56 +22,14 @@ class AttackArrowObject extends Base { | ||||
|    * @param sdk | ||||
|    * @description 箭头面 | ||||
|    * @param options {object} 属性 | ||||
|    * @param options.id {string} 唯一标识 | ||||
|    * @param options.show=true {boolean} 显示/隐藏 | ||||
|    * @param options.name {string} 名称 | ||||
|    * @param options.color='rgba(255, 0, 0, 0.5)' {string} 颜色 | ||||
|    * @param options.color="#ff000080" {string} 颜色 | ||||
|    * @param options.height {number} 高度 | ||||
|    * @param options.heightMode=2{number} 高度模式(0:海拔高度;1:相对地表;2:依附模式) | ||||
|    * @param options.areaUnit='平方米' {string} 面积单位 | ||||
|    * @param options.line {object} 边框 | ||||
|    * @param options.line.width=2 {string} 边框宽 | ||||
|    * @param options.line.color="rgba(155, 155, 124, 0.89)" {string} 边框颜色 | ||||
|    * @param {Array.<object>} options.positions 必填,经纬度和高度的列表,值交替 [{lon,lat,alt},...] | ||||
|    * @param options.positions[].lng {number} 经度 | ||||
|    * @param options.positions[].lat {number} 纬度 | ||||
|    * @param options.positions[].alt {number} 高度 | ||||
|    * @param options.spreadState=false {boolean} 动画 | ||||
|    * @param options.loop=false {loop} 动画重复 | ||||
|    * @param options.spreadTime=3000 {number} 动画持续时长(毫秒) | ||||
|    * @param options.label {object} 标签对象 | ||||
|    * @param options.label.text {string} 标签文本 | ||||
|    * @param options.label.show {string} 标签显隐 | ||||
|    * @param options.label.position {string} 标签位置 | ||||
|    * @param options.label.position {object} 标签位置 | ||||
|    * @param options.label.position.lng {number} 经度 | ||||
|    * @param options.label.position.lat {number} 纬度 | ||||
|    * @param options.label.position.alt {number} 高度 | ||||
|    * @param options.label.fontSize=20 {number} 字体大小 | ||||
|    * @param options.label.fontFamily=0 {number} 字体项 0:黑体;1:思源黑体;2:庞门正道标题体;3:数黑体 | ||||
|    * @param options.label.color=#ffffff {string} 字体颜色 | ||||
|    * @param options.label.lineWidth=4 {number} 引线宽 | ||||
|    * @param options.label.lineColor=#00ffff80 {string} 引线颜色 | ||||
|    * @param options.label.pixelOffset=20 {number} 字体偏移(引线长度) | ||||
|    * @param options.label.backgroundColor=['#00ffff80', '#00ffff80'] {array} 背景颜色 | ||||
|    * @param options.label.scaleByDistance {boolean} 距离缩放 | ||||
|    * @param options.label.near=2000 {number} 视野缩放最近距离 | ||||
|    * @param options.label.far=100000 {number} 视野缩放最远距离 | ||||
|    * @param options.attribute {object} 属性内容 | ||||
|    * @param options.attribute.link={} {object} 链接 | ||||
|    * @param options.attribute.link.content=[]] {array} 链接内容 | ||||
|    * @param options.attribute.link.content[].name {string} 链接名称 | ||||
|    * @param options.attribute.link.content[].url {string} 链接地址 | ||||
|    * @param options.richTextContent {string} 富文本内容 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    * @param {Array.<object>} options.positions 坐标数组 [{lon,lat,alt},...] | ||||
|    * @param _Dialog {object} 弹框事件 | ||||
|    * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    * */ | ||||
|   constructor(sdk, options = {}, _Dialog = {}) { | ||||
|     super(sdk, options); | ||||
|  | ||||
| @ -17,62 +17,30 @@ import { setActiveViewer, closeRotateAround, closeViewFollow } from '../../../.. | ||||
| class Model extends BaseModel { | ||||
|   #timeoutEventObject = null | ||||
|   /** | ||||
|    * @constructor | ||||
|    * @description 加载模型 | ||||
|    * @param sdk {object} sdk | ||||
|    * @param options {object} 模型参数 | ||||
|    * @param options.id {string} 唯一标识 | ||||
|    * @param options.show=true {boolean} 模型显隐 | ||||
|    * @param options.name {string} 名称 | ||||
|    * @param options.url {string} 资源地址 | ||||
|    * @param options.position {object} 模型位置 | ||||
|    * @param options.position.lng {number} 经度 | ||||
|    * @param options.position.lat {number} 纬度 | ||||
|    * @param options.position.alt {number} 高度 | ||||
|    * @param options.scale {object} 比例 | ||||
|    * @param options.scale.x=1 {number} x轴比例 | ||||
|    * @param options.scale.y=1 {number} y轴比例 | ||||
|    * @param options.scale.z=1 {number} z轴比例 | ||||
|    * @param options.maximumScale=100 {number} 最大比例 | ||||
|    * @param options.minimumPixelSize=60 {number} 最小像素 | ||||
|    * @param options.scaleByDistance=true {boolean} 随视野缩放 | ||||
|    * @param options.rotate {object} 旋转角度 | ||||
|    * @param options.rotate.x {number} x轴旋转度数 | ||||
|    * @param options.rotate.y {number} y轴旋转度数 | ||||
|    * @param options.rotate.z {number} z轴旋转度数 | ||||
|    * @param options.label {object} 标签对象 | ||||
|    * @param options.label.text {string} 标签文本 | ||||
|    * @param options.label.show {string} 标签显隐 | ||||
|    * @param options.label.position {string} 标签位置 | ||||
|    * @param options.label.position {object} 标签位置 | ||||
|    * @param options.label.position.lng {number} 经度 | ||||
|    * @param options.label.position.lat {number} 纬度 | ||||
|    * @param options.label.position.alt {number} 高度 | ||||
|    * @param options.label.fontSize=20 {number} 字体大小 | ||||
|    * @param options.label.fontFamily=0 {number} 字体项 0:黑体;1:思源黑体;2:庞门正道标题体;3:数黑体 | ||||
|    * @param options.label.color=#ffffff {string} 字体颜色 | ||||
|    * @param options.label.lineWidth=4 {number} 引线宽 | ||||
|    * @param options.label.lineColor=#00ffff80 {string} 引线颜色 | ||||
|    * @param options.label.pixelOffset=20 {number} 字体偏移(引线长度) | ||||
|    * @param options.label.backgroundColor=['#00ffff80', '#00ffff80'] {array} 背景颜色 | ||||
|    * @param options.label.scaleByDistance {boolean} 距离缩放 | ||||
|    * @param options.label.near=2000 {number} 视野缩放最近距离 | ||||
|    * @param options.label.far=100000 {number} 视野缩放最远距离 | ||||
|    * @param options.attribute {object} 属性内容 | ||||
|    * @param {object} options.attribute.link={} 链接 | ||||
|    * @param options.attribute.link.content=[]] {array} 链接内容 | ||||
|    * @param options.attribute.link.content[].name {string} 链接名称 | ||||
|    * @param options.attribute.link.content[].url {string} 链接地址 | ||||
|    * @param options.richTextContent {string} 富文本内容 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
| * @constructor | ||||
| * @description 加载模型 | ||||
| * @param sdk {object} sdk | ||||
| * @param options {object} 模型参数 | ||||
| * @param options.id {string} 对象id | ||||
| * @param options.show=true {boolean} 模型显隐 | ||||
| * @param options.name {string} 名称 | ||||
| * @param options.url {string} 资源地址 | ||||
| * @param options.position {object} 模型位置 | ||||
| * @param options.position.lng {number} 经度 | ||||
| * @param options.position.lat {number} 纬度 | ||||
| * @param options.position.alt {number} 高度 | ||||
| * @param options.scale {object} 比例 | ||||
| * @param options.scale.x=1 {number} 比例 | ||||
| * @param options.scale.y=1 {number} 比例 | ||||
| * @param options.scale.z=1 {number} 比例 | ||||
| * @param options.maximumScale=100 {number} 最大比例 | ||||
| * @param options.minimumPixelSize=60 {number} 最小像素 | ||||
| * @param options.scaleByDistance=true {boolean} 随视野缩放 | ||||
| * @param options.rotate {object} 旋转角度 | ||||
| * @param options.rotate.x {number} x轴旋转度数 | ||||
| * @param options.rotate.y {number} y轴旋转度数 | ||||
| * @param options.rotate.z {number} z轴旋转度数 | ||||
| * @param options.img {string} 图片地址 | ||||
| * */ | ||||
|   constructor(earth, options = {}, _Dialog = {}) { | ||||
|     super(earth, options, _Dialog = {}) | ||||
|  | ||||
| @ -48,64 +48,30 @@ class BillboardObject extends Base { | ||||
|  | ||||
|   /** | ||||
|    * @constructor | ||||
|    * @description 点标注 | ||||
|    * @param options {object} 属性 | ||||
|    * @description 创建点标注 | ||||
|    * @param sdk {object} sdk | ||||
|    * @param options {object} 标注参数 | ||||
|    * @param options.id {string} 标注id | ||||
|    * @param options.show=true {boolean} 标注整体的显隐 | ||||
|    * @param options.name {string} 名称 | ||||
|    * @param {object} options.position={} 必填,位置 | ||||
|    * @param {number} options.position.lng 经度 | ||||
|    * @param {number} options.position.lat 纬度 | ||||
|    * @param {number} options.position.alt 高度 | ||||
|    * @param {object} options.positions 位置 | ||||
|    * @param {number} options.positions.lng 经度 | ||||
|    * @param {number} options.positions.lat 纬度 | ||||
|    * @param {number} options.positions.alt 高度 | ||||
|    * @param {number} options.heightMode=3 高度模式(0:海拔高度;1:相对地表;2:依附地表; 3:依附模型) | ||||
|    * @param [options.scaleByDistance=true] {boolean} 是否开启跟随视野缩放 | ||||
|    * @param [options.near=2000] {number} 视野缩放最近距离 | ||||
|    * @param [options.far=100000]  {number} 视野缩放最远距离 | ||||
|    * @param options.billboard {object} 图标参数 | ||||
|    * @param [options.billboard.show=true] {boolean} 图标显隐 | ||||
|    * @param [options.scaleByDistance=true] {boolean} 图标是否跟随视角变化进行字段缩放 | ||||
|    * @param [options.show=true] {boolean} 标注整体的显示/隐藏 | ||||
|    * @param [options.near=2000] {number} 近端可视距离 scaleByDistance为true时生效 | ||||
|    * @param [options.far=100000]  {number} 远端可视距离 scaleByDistance为true时生效 | ||||
|    * @param options.billboard {object} 标注中图标的参数 | ||||
|    * @param [options.billboard.show=true] {boolean} 标注中图标的显示与隐藏 | ||||
|    * @param options.billboard.image {string} 图标路径 | ||||
|    * @param options.billboard.defaultImage {string} 默认图标的唯一标识 | ||||
|    * @param [options.billboard.scale=3] {number} 图标放大倍数 | ||||
|    * @param options.label {object} 文字参数 | ||||
|    * @param [options.label.text] {string} 文字内容 | ||||
|    * @param [options.label.show=true] {boolean} 文字显隐 | ||||
|    * @param [options.label.fontFamily=0] {number} 文字字体项 0:黑体;1:思源黑体;2:庞门正道标题体;3:数黑体 | ||||
|    * @param [options.label.fontSize=39] {number} 文字大小, 单位px | ||||
|    * @param [options.label.color=#00ffff] {string} 文字颜色 | ||||
|    * @param options.attribute {object} 属性内容 | ||||
|    * @param {object} options.attribute.link={}  链接 | ||||
|    * @param options.attribute.link.content=[]] {array} 链接内容 | ||||
|    * @param options.attribute.link.content[].name {string} 链接名称 | ||||
|    * @param options.attribute.link.content[].url {string} 链接地址 | ||||
|    * @param {object} options.attribute.vr={} 全景图 | ||||
|    * @param options.attribute.vr.content=[]] {array} 全景图内容 | ||||
|    * @param options.attribute.vr.content[].name {string} 名称 | ||||
|    * @param options.attribute.vr.content[].url {string} 地址 | ||||
|    * @param {object} ptions.attribute.camera={} 摄像头 | ||||
|    * @param options.attribute.camera.content=[]] {array} 摄像头内容 | ||||
|    * @param {object} options.attribute.ISC={} ISC | ||||
|    * @param options.attribute.ISC.content=[]] {array} ISC内容 | ||||
|    * @param {object} options.attribute.goods={} 物资 | ||||
|    * @param options.attribute.goods.content=[]] {array} 物资内容 | ||||
|    * @param options.attribute.goods.content[].ID {string} ID | ||||
|    * @param options.attribute.goods.content[].name {string} 名称 | ||||
|    * @param options.attribute.goods.content[].cnt {string} 数量 | ||||
|    * @param options.richTextContent {string} 富文本内容 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    *  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|    * @param [options.billboard.scale=3] {number} 图标倍数 | ||||
|    *@param options.label {object} 标注文字的参数 | ||||
|    *@param [options.label.text] {string} 标注中文字 | ||||
|    *@param [options.label.show=true] {boolean} 标注文字显示/隐藏 | ||||
|    *@param [options.label.fontFamily=0] {number} 标注文字字体 0:黑体;1:思源黑体;2:庞门正道标题体;3:数黑体 | ||||
|    *@param [options.label.fontSize=39] {number} 标注文字大小 单位px,微软雅黑 | ||||
|    *@param [options.label.color=#00ffff] {string} 标注文字颜色 | ||||
|    *@param _Dialog {object} 弹框事件 | ||||
|    *@param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    *@param _Dialog.instructSubmit(id,name,instruct) {function} 提交指令(ID, 名称,指令内容) | ||||
|  | ||||
| @ -21,53 +21,23 @@ class CircleDiffuse extends Base { | ||||
|    * @param sdk  | ||||
|    * @param options {object} 圆属性 | ||||
|    * @param options.id {string} 标注id | ||||
|    * @param options.show=true {boolean} 显示/隐藏 | ||||
|    * @param [options.show=true] {boolean} 显示/隐藏 | ||||
|    * @param options.lng {number} 经度 | ||||
|    * @param options.lat {number} 维度 | ||||
|    * @param options.color=#1FA8E3 {string} 基础颜色 | ||||
|    * @param options.colors=[] {string} 范围颜色 | ||||
|    * @param options.speed=5 {number} 速度 | ||||
|    * @param options.count=3 {number} 波纹数量 | ||||
|    * @param options.circle=[]] {array} 圆属性 | ||||
|    * @param options.circle[].radius {number} 半径 | ||||
|    * @param options.circle[].color {string} 颜色 | ||||
|    * @param options.label {object} 标签对象 | ||||
|    * @param options.label.show {string} 标签显隐 | ||||
|    * @param options.label.position {string} 标签位置 | ||||
|    * @param options.label.position {object} 标签位置 | ||||
|    * @param options.label.position.lng {number} 经度 | ||||
|    * @param options.label.position.lat {number} 纬度 | ||||
|    * @param options.label.position.alt {number} 高度 | ||||
|    * @param options.label.fontSize=20 {number} 字体大小 | ||||
|    * @param options.label.fontFamily=0 {number} 字体项 0:黑体;1:思源黑体;2:庞门正道标题体;3:数黑体 | ||||
|    * @param options.label.color=#ffffff {string} 字体颜色 | ||||
|    * @param options.label.lineWidth=4 {number} 引线宽 | ||||
|    * @param options.label.lineColor=#00ffff80 {string} 引线颜色 | ||||
|    * @param options.label.pixelOffset=20 {number} 字体偏移(引线长度) | ||||
|    * @param options.label.backgroundColor=['#00ffff80', '#00ffff80'] {array} 背景颜色 | ||||
|    * @param options.label.scaleByDistance {boolean} 距离缩放 | ||||
|    * @param options.label.near=2000 {number} 视野缩放最近距离 | ||||
|    * @param options.label.far=100000 {number} 视野缩放最远距离 | ||||
|    * @param options.attribute {object} 属性内容 | ||||
|    * @param {object} options.attribute.link={} 链接 | ||||
|    * @param options.attribute.link.content=[]] {array} 链接内容 | ||||
|    * @param options.attribute.link.content[].name {string} 链接名称 | ||||
|    * @param options.attribute.link.content[].url {string} 链接地址 | ||||
|    * @param options.richTextContent {string} 富文本内容 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    * @param options.circle=[{radius, color}] {object} 圆属性;radius:半径,color:颜色 | ||||
|    * @param _Dialog {object} 弹框事件 | ||||
|    * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    */ | ||||
|   constructor(sdk, options = {}, _Dialog = {}) { | ||||
|     super(sdk, options); | ||||
|     this.options.lng = options.lng | ||||
|     this.options.lat = options.lat | ||||
|     this.options.color = options.color || '#1FA8E3' | ||||
|     this.options.colors = options.colors || [] | ||||
|     this.options.transparency = (options.transparency || options.transparency === 0) ? options.transparency : 1 | ||||
|     if (this.options.transparency > 1) { | ||||
|       this.options.transparency = 1 | ||||
| @ -460,6 +430,15 @@ class CircleDiffuse extends Base { | ||||
|     }) | ||||
|   } | ||||
|  | ||||
|   get colors() { | ||||
|     return this.options.colors | ||||
|   } | ||||
|  | ||||
|   set colors(v) { | ||||
|     this.options.colors = v | ||||
|     CircleDiffuse.create(this) | ||||
|   } | ||||
|  | ||||
|   get labelShow() { | ||||
|     return this.options.label.show | ||||
|   } | ||||
|  | ||||
| @ -18,63 +18,22 @@ import { setActiveViewer, closeRotateAround, closeViewFollow } from '../../../Gl | ||||
| class CircleObject extends Base { | ||||
|   /** | ||||
|    * @constructor | ||||
|    * @param sdk | ||||
|    * @description 创建圆 | ||||
|    * @param options {object} 圆属性 | ||||
|    * @param options.id {string} 标注id | ||||
|    * @param options.name {string} 名称 | ||||
|    * @param options.show=true {boolean} 显示/隐藏 | ||||
|    * @param options.color="#ff000080" {string} 颜色 | ||||
|    * @param options.center {object} 中心位置 | ||||
|    * @param options.center.lng {number} 经度 | ||||
|    * @param options.center.lat {number} 纬度 | ||||
|    * @param options.center.alt {number} 高度 | ||||
|    * @param options.radius=10 {number}半径 | ||||
|    * @param options.center {object} 位置 | ||||
|    * @param options.center.lng {object} 经度 | ||||
|    * @param options.center.lat {object} 纬度 | ||||
|    * @param options.center.alt {object} 高度 | ||||
|    * @param options.radius=10 {object}半径 | ||||
|    * @param options.line {object} 边框 | ||||
|    * @param options.line.width=3 {number} 边框宽 | ||||
|    * @param options.line.width=2 {string} 边框宽 | ||||
|    * @param options.line.color="#ff000080" {string} 边框颜色 | ||||
|    * @param options.label {object} 标注 | ||||
|    * @param options.heightMode=2{number} 高度模式(0:海拔高度;1:相对地表;2:依附模式) | ||||
|    * @param options.areaUnit='平方米' {string} 面积单位 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    * @param options.label {object} 标签对象 | ||||
|    * @param options.label.text {string} 标签文本 | ||||
|    * @param options.label.show {string} 标签显隐 | ||||
|    * @param options.label.position {object} 标签位置 | ||||
|    * @param options.label.position.lng {number} 经度 | ||||
|    * @param options.label.position.lat {number} 纬度 | ||||
|    * @param options.label.position.alt {number} 高度 | ||||
|    * @param options.label.fontSize=20 {number} 字体大小 | ||||
|    * @param options.label.fontFamily=0 {number} 字体项 0:黑体;1:思源黑体;2:庞门正道标题体;3:数黑体 | ||||
|    * @param options.label.color=#ffffff {string} 字体颜色 | ||||
|    * @param options.label.lineWidth=4 {number} 引线宽 | ||||
|    * @param options.label.lineColor=#00ffff80 {string} 引线颜色 | ||||
|    * @param options.label.pixelOffset=20 {number} 字体偏移(引线长度) | ||||
|    * @param options.label.backgroundColor=['#00ffff80', '#00ffff80'] {array} 背景颜色 | ||||
|    * @param options.label.scaleByDistance {boolean} 距离缩放 | ||||
|    * @param options.label.near=2000 {number} 视野缩放最近距离 | ||||
|    * @param options.label.far=100000 {number} 视野缩放最远距离 | ||||
|    * @param options.attribute {object} 属性内容 | ||||
|    * @param options.attribute.link {object} 链接 | ||||
|    * @param options.attribute.link.content=[]] {array} 链接内容 | ||||
|    * @param options.attribute.link.content[].name {string} 链接名称 | ||||
|    * @param options.attribute.link.content[].url {string} 链接地址 | ||||
|    * @param options.richTextContent {string} 富文本内容 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    */ | ||||
|   constructor(sdk, options = {}) { | ||||
|     super(sdk, options); | ||||
|  | ||||
| @ -21,57 +21,30 @@ class CurvelineObject extends Base { | ||||
|   /** | ||||
|    * @constructor | ||||
|    * @param sdk | ||||
|    * @description 曲线 | ||||
|    * @description 折线 | ||||
|    * @param options {object} 线属性 | ||||
|    * @param options.name{string} 名称 | ||||
|    * @param options.width=3{number} 线宽 | ||||
|    * @param options.color=#ff0000 {string} 颜色 | ||||
|    * @param options.type=0 {number} 材质类型 0-实线 1-虚线 2-泛光... | ||||
|    * @param options.heightMode=2{number} 高度模式(0:海拔高度;1:相对高度;2:依附模式) | ||||
|    * @param options.noseToTail=false {boolean} 首尾相连 | ||||
|    * @param options.type=0 {number} 材质类型 0-实线 1-虚线 2-泛光 | ||||
|    * @param options.heightMode{number} 高度模式(0:海拔高度;1:相对高度;2:依附模式) | ||||
|    * @param options['nose-to-tail']=false {boolean} 首尾相连 | ||||
|    * @param options.extend=false {boolean} 线缓冲 | ||||
|    * @param options.extendWidth=10 {number} 线缓冲宽度 | ||||
|    * @param options.extendColor=rgba(255,255,80,0.3) {number} 线缓冲颜色 | ||||
|    * @param options['extend-width']=10 {number} 线缓冲宽度 | ||||
|    * @param options['extend-color']=#ffde00 {number} 线缓冲颜色 | ||||
|    * @param options.show=true {boolean} 显隐 | ||||
|    * @param {Array.<object>} options.positions 必填,经纬度和高度的列表,值交替 [{lon,lat,alt},...] | ||||
|    * @param options.positions[].lng {number} 经度 | ||||
|    * @param options.positions[].lat {number} 纬度 | ||||
|    * @param options.positions[].alt {number} 高度 | ||||
|    * @param options.label {object} 标签对象 | ||||
|    * @param options.label.text {string} 标签文本 | ||||
|    * @param options.label.show {string} 标签显隐 | ||||
|    * @param options.label.position {string} 标签位置 | ||||
|    * @param options.label.position {object} 标签位置 | ||||
|    * @param options.label.position.lng {number} 经度 | ||||
|    * @param options.label.position.lat {number} 纬度 | ||||
|    * @param options.label.position.alt {number} 高度 | ||||
|    * @param options.label.fontSize=20 {number} 字体大小 | ||||
|    * @param options.label.fontFamily=0 {number} 字体项 0:黑体;1:思源黑体;2:庞门正道标题体;3:数黑体 | ||||
|    * @param options.label.color=#ffffff {string} 字体颜色 | ||||
|    * @param options.label.lineWidth=4 {number} 引线宽 | ||||
|    * @param options.label.lineColor=#00ffff80 {string} 引线颜色 | ||||
|    * @param options.label.pixelOffset=20 {number} 字体偏移(引线长度) | ||||
|    * @param options.label.backgroundColor=['#00ffff80', '#00ffff80'] {array} 背景颜色 | ||||
|    * @param options.label.scaleByDistance {boolean} 距离缩放 | ||||
|    * @param options.label.near=2000 {number} 视野缩放最近距离 | ||||
|    * @param options.label.far=100000 {number} 视野缩放最远距离 | ||||
|    * @param options.attribute {object} 属性内容 | ||||
|    * @param options.attribute.link={} {string} 链接 | ||||
|    * @param options.attribute.link.content=[]] {array} 链接内容 | ||||
|    * @param options.attribute.link.content[].name {string} 链接名称 | ||||
|    * @param options.attribute.link.content[].url {string} 链接地址 | ||||
|    * @param options.richTextContent {string} 富文本内容 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    *  | ||||
|    *  | ||||
|    * @param {Array.<object>} options.positions 坐标数组 [{lng,lat},...] | ||||
|    * @param options.label {object} 标注 | ||||
|    * @param options.label.show=false {boolean} 标注显隐 | ||||
|    * @param options.label.fontSize=20 {number} 标注字体大小 | ||||
|    * @param options.label.color=#ffffff {string} 标注字体颜色 | ||||
|    * @param options.label.lineWidth=1 {number} 标注引线宽 | ||||
|    * @param options.label.pixelOffset=20 {string} 标注引线长度 | ||||
|    * @param options.label.backgroundColor=['#42c6ef', '#42c6ef'] {Array} 标注背景 | ||||
|    * @param options.label.lineColor=#fff000 {string} 标注引线颜色 | ||||
|    * @param options.label.scaleByDistance=false {boolean} 标注是否随视野缩放 | ||||
|    * @param options.label.near=2000 {boolean} 标注随视野缩放最近距离 | ||||
|    * @param options.label.far=100000 {boolean} 标注随视野缩放最远距离 | ||||
|    * @param _Dialog {object} 弹框事件 | ||||
|    * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    * */ | ||||
|  | ||||
| @ -18,13 +18,12 @@ import { setActiveViewer, closeRotateAround, closeViewFollow } from '../../../Gl | ||||
| class EllipseObject extends Base { | ||||
|   /** | ||||
|    * @constructor | ||||
|    * @param sdk | ||||
|    * @description 创建椭圆 | ||||
|    * @param options {object} 圆属性 | ||||
|    * @param options.id {string} 标注id | ||||
|    * @param options.name {string} 名称 | ||||
|    * @param options.show=true {boolean} 显示/隐藏 | ||||
|    * @param options.center {object} 中心位置 | ||||
|    * @param options.center {object} 位置 | ||||
|    * @param options.color="rgba(255, 0, 0, 0.5)" {string} 颜色 | ||||
|    * @param options.center.lng {object} 经度 | ||||
|    * @param options.center.lat {object} 维度 | ||||
| @ -34,41 +33,8 @@ class EllipseObject extends Base { | ||||
|    * @param options.line {object} 边框 | ||||
|    * @param options.line.width=2 {string} 边框宽 | ||||
|    * @param options.line.color="rgba(255, 0, 0, 1)" {string} 边框颜色 | ||||
|    * @param options.label {object} 标注 | ||||
|    * @param options.heightMode=2{number} 高度模式(0:海拔高度;1:相对地表;2:依附模式) | ||||
|    * @param options.areaUnit='平方米' {string} 面积单位 | ||||
|    * @param options.label {object} 标签对象 | ||||
|    * @param options.label.text {string} 标签文本 | ||||
|    * @param options.label.show {string} 标签显隐 | ||||
|    * @param options.label.position {string} 标签位置 | ||||
|    * @param options.label.position {object} 标签位置 | ||||
|    * @param options.label.position.lng {number} 经度 | ||||
|    * @param options.label.position.lat {number} 纬度 | ||||
|    * @param options.label.position.alt {number} 高度 | ||||
|    * @param options.label.fontSize=20 {number} 字体大小 | ||||
|    * @param options.label.fontFamily=0 {number} 字体项 0:黑体;1:思源黑体;2:庞门正道标题体;3:数黑体 | ||||
|    * @param options.label.color=#ffffff {string} 字体颜色 | ||||
|    * @param options.label.lineWidth=4 {number} 引线宽 | ||||
|    * @param options.label.lineColor=#00ffff80 {string} 引线颜色 | ||||
|    * @param options.label.pixelOffset=20 {number} 字体偏移(引线长度) | ||||
|    * @param options.label.backgroundColor=['#00ffff80', '#00ffff80'] {array} 背景颜色 | ||||
|    * @param options.label.scaleByDistance {boolean} 距离缩放 | ||||
|    * @param options.label.near=2000 {number} 视野缩放最近距离 | ||||
|    * @param options.label.far=100000 {number} 视野缩放最远距离 | ||||
|    * @param options.attribute {object} 属性内容 | ||||
|    * @param options.attribute.link {object} 链接 | ||||
|    * @param options.attribute.link.content=[]] {array} 链接内容 | ||||
|    * @param options.attribute.link.content[].name {string} 链接名称 | ||||
|    * @param options.attribute.link.content[].url {string} 链接地址 | ||||
|    * @param options.richTextContent {string} 富文本内容 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    */ | ||||
|   constructor(sdk, options = {}) { | ||||
|     super(sdk, options); | ||||
|  | ||||
| @ -13,15 +13,6 @@ class Explosion extends Base { | ||||
|   * @description 爆炸 | ||||
|   * @param sdk | ||||
|   * @param options {object} 爆炸属性 | ||||
|   * @param options.id {string} 唯一标识 | ||||
|   * @param options.show=true {boolean} 显隐 | ||||
|   * @param options.name {string} 名称 | ||||
|   * @param {object} options.position={} 位置 | ||||
|   * @param {number} options.position.lng 经度 | ||||
|   * @param {number} options.position.lat 纬度 | ||||
|   * @param {number} options.position.alt 高度 | ||||
|   * @param options.scaleByDistance=true {boolean} 是否开启跟随视野缩放 | ||||
|   * @param options.size=80 {number} 大小(爆炸范围) | ||||
|   * */ | ||||
|   constructor(sdk, options = {}, _Dialog = {}) { | ||||
|     super(sdk, options); | ||||
|  | ||||
| @ -9,25 +9,6 @@ import { setActiveViewer, closeRotateAround, closeViewFollow} from '../../../Glo | ||||
|  | ||||
| class FlyRoam extends Base { | ||||
|   #clickHandler = undefined | ||||
|   /** | ||||
|    * @constructor | ||||
|    * @param sdk | ||||
|    * @description 飞行漫游 | ||||
|    * @param options {object} | ||||
|    * @param options.id {string} 标注id | ||||
|    * @param options.name {string} 名称 | ||||
|    * @param options.repeat=0 {number} 重复次数 | ||||
|    * @param options.points=[]] {array} 视点列表 | ||||
|    * @param options.points[].position {object} 视点位置 | ||||
|    * @param options.points[].position.lng {number} 经度 | ||||
|    * @param options.points[].position.lat {number} 纬度 | ||||
|    * @param options.points[].position.alt {number} 高度 | ||||
|    * @param options.points[].orientation {object} 视点方向 | ||||
|    * @param options.points[].orientation.heading=0 {number} 视点航向角 | ||||
|    * @param options.points[].orientation.pitch=0 {number} 视点俯仰角 | ||||
|    * @param options.points[].orientation.roll=0 {number} 视点翻滚角 | ||||
|    * @param options.points[].duration=0 {number} 持续时间 | ||||
|    **/ | ||||
|   constructor(sdk, options = {}, _Dialog = {}) { | ||||
|     super(sdk, options) | ||||
|     this.options.id = options.id || this.randomString() | ||||
|  | ||||
| @ -26,7 +26,7 @@ class GroundSvg extends Base { | ||||
|    * @param options.scale {object} 比例 | ||||
|    * @param options.scale.x=1 {number} x轴比例 | ||||
|    * @param options.scale.y=1 {number} y轴比例 | ||||
|    * @param options.url {string} 资源地址 | ||||
|    * @param options.url {string} svg图片地址 | ||||
|    * @param options.flipe {object} 翻转 | ||||
|    * @param options.flipe.x=false {boolean} 绕X轴翻转 | ||||
|    * @param options.flipe.y=false {boolean} 绕Y轴翻转 | ||||
| @ -34,31 +34,8 @@ class GroundSvg extends Base { | ||||
|    * @param options.position.lng {number} 经度 | ||||
|    * @param options.position.lat {number} 纬度 | ||||
|    * @param options.color {string} 颜色 | ||||
|    * @param options.text {object} 文字 | ||||
|    * @param options.text.show=true {boolean} 文字 | ||||
|    * @param options.text.position.lng {number} 经度 | ||||
|    * @param options.text.position.lat {number} 纬度 | ||||
|    * @param options.text.position.alt {number} 高度 | ||||
|    * @param options.text.fontSize=20 {number} 字体大小 | ||||
|    * @param options.text.color=#ffffff {string} 字体大小 | ||||
|    * @param options.text.scaleByDistance {boolean} 距离缩放 | ||||
|    * @param options.text.near=2000 {number} 视野缩放最近距离 | ||||
|    * @param options.text.far=100000 {number} 视野缩放最远距离 | ||||
|    * @param options.attribute {object} 属性内容 | ||||
|    * @param {object} options.attribute.link={} 链接 | ||||
|    * @param options.attribute.link.content=[]] {array} 链接内容 | ||||
|    * @param options.attribute.link.content[].name {string} 链接名称 | ||||
|    * @param options.attribute.link.content[].url {string} 链接地址 | ||||
|    * @param options.richTextContent {string} 富文本内容 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    * @param _Dialog {object} 弹框事件 | ||||
|    * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    * */ | ||||
|   #loadEvent = void 0 | ||||
|   #loaded = false | ||||
|  | ||||
| @ -18,10 +18,9 @@ class Flame extends Base { | ||||
|    * @description 火焰特效 | ||||
|    * @param sdk  | ||||
|    * @param options {object} 粒子属性 | ||||
|    * @param options.id {string} 标注id | ||||
|    * @param options.show=true {boolean} 显示/隐藏 | ||||
|    * @param options.name {string} 名称 | ||||
|    * @param options.url {string} 贴图地址 | ||||
|    * @param options.url {string | HTMLImageElement | HTMLCanvasElement | HTMLVideoElement} 指定 Image、URL或Canvas 的属性 | ||||
|    * @param options.startColor="#ff0000" {string} 起始颜色 | ||||
|    * @param options.endColor="#fff000" {string} 结束颜色 | ||||
|    * @param options.startScale=0.5 {number} 初始比例 | ||||
| @ -35,15 +34,8 @@ class Flame extends Base { | ||||
|    * @param options.lng 经度 | ||||
|    * @param options.lat 纬度 | ||||
|    * @param options.alt 高度 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    * @param _Dialog {object} 弹框事件 | ||||
|    * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    * */ | ||||
|   constructor(sdk, options, _Dialog = {}) { | ||||
|     super(sdk, options); | ||||
|  | ||||
| @ -17,10 +17,9 @@ class Fountain extends Base { | ||||
|    * @description 喷泉特效 | ||||
|    * @param sdk  | ||||
|    * @param options {object} 粒子属性 | ||||
|    * @param options.id {string} 标注id | ||||
|    * @param options.show=true {boolean} 显示/隐藏 | ||||
|    * @param options.name {string} 名称 | ||||
|    * @param options.url {string} 贴图地址 | ||||
|    * @param options.url {string | HTMLImageElement | HTMLCanvasElement | HTMLVideoElement} 指定 Image、URL或Canvas 的属性 | ||||
|    * @param options.startColor="#c1f7f24d" {string} 起始颜色 | ||||
|    * @param options.endColor="#ffffff00" {string} 结束颜色 | ||||
|    * @param options.startScale=1 {number} 初始比例 | ||||
| @ -31,18 +30,12 @@ class Fountain extends Base { | ||||
|    * @param options.maximumParticleLife=7 {number} 最大存在时间(秒) | ||||
|    * @param options.emissionRate=20 {number} 发射速率(个/每秒) | ||||
|    * @param options.particleSize=0.5{number} 粒子尺大小 | ||||
|    * @param options.gravity=-3.5{number} 重力值 | ||||
|    * @param options.lng 经度 | ||||
|    * @param options.lat 纬度 | ||||
|    * @param options.alt 高度 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    * @param _Dialog {object} 弹框事件 | ||||
|    * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    * */ | ||||
|   constructor(sdk, options, _Dialog = {}) { | ||||
|     super(sdk, options); | ||||
| @ -57,7 +50,7 @@ class Fountain extends Base { | ||||
|     this.options.maximumSpeed = options.maximumSpeed || 9.5 | ||||
|     this.options.emissionRate = options.emissionRate || 20 | ||||
|     this.options.particleSize = options.particleSize || 0.5 | ||||
|     // this.options.gravity = (options.gravity || options.gravity === 0) ? options.gravity : -3.5 | ||||
|     this.options.gravity = (options.gravity || options.gravity === 0) ? options.gravity : -3.5 | ||||
|     this.options.show = options.show === false ? false : true | ||||
|     this._elms = {}; | ||||
|     this.positionCallBack = null | ||||
|  | ||||
| @ -17,10 +17,9 @@ class Smoke extends Base { | ||||
|    * @description 烟雾特效 | ||||
|    * @param sdk | ||||
|    * @param options {object} 粒子属性 | ||||
|    * @param options.id {string} 标注id | ||||
|    * @param options.show=true {boolean} 显示/隐藏 | ||||
|    * @param options.name {string} 名称 | ||||
|    * @param options.url {string} 贴图地址 | ||||
|    * @param options.url {string | HTMLImageElement | HTMLCanvasElement | HTMLVideoElement} 指定 Image、URL或Canvas 的属性 | ||||
|    * @param options.startColor="#00000000" {string} 起始颜色 | ||||
|    * @param options.endColor="#0000001a" {string} 结束颜色 | ||||
|    * @param options.startScale=0.1 {number} 初始比例 | ||||
| @ -34,15 +33,8 @@ class Smoke extends Base { | ||||
|    * @param options.lng 经度 | ||||
|    * @param options.lat 纬度 | ||||
|    * @param options.alt 高度 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    * @param _Dialog {object} 弹框事件 | ||||
|    * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    * */ | ||||
|   constructor(sdk, options, _Dialog = {}) { | ||||
|     super(sdk, options); | ||||
|  | ||||
| @ -16,10 +16,9 @@ class Spout extends Base { | ||||
|    * @description 水柱 | ||||
|    * @param sdk  | ||||
|    * @param options {object} 粒子属性 | ||||
|    * @param options.id {string} 标注id | ||||
|    * @param options.show=true {boolean} 显示/隐藏 | ||||
|    * @param options.name {string} 名称 | ||||
|    * @param options.url {string} 贴图地址 | ||||
|    * @param options.url {string | HTMLImageElement | HTMLCanvasElement | HTMLVideoElement} 指定 Image、URL或Canvas 的属性 | ||||
|    * @param options.startColor="#c1f7f2" {string} 起始颜色 | ||||
|    * @param options.endColor="#ffffff00" {string} 结束颜色 | ||||
|    * @param options.startScale=0.2 {number} 初始比例 | ||||
| @ -29,8 +28,8 @@ class Spout extends Base { | ||||
|    * @param options.maximumParticleLife=12 {number} 最大存在时间(秒) | ||||
|    * @param options.emissionRate=100 {number} 发射速率(个/每秒) | ||||
|    * @param options.particleSize=1 {number} 粒子尺大小 | ||||
|    * @param options.heading 航向角 | ||||
|    * @param options.pitch 俯仰角 | ||||
|    * @param options.heading 朝向 | ||||
|    * @param options.pitch 俯仰角度 | ||||
|    * @param options.start {object} 开始位置 | ||||
|    * @param options.start.lng 经度 | ||||
|    * @param options.start.lat 纬度 | ||||
| @ -39,15 +38,8 @@ class Spout extends Base { | ||||
|    * @param options.end.lng 经度 | ||||
|    * @param options.end.lat 纬度 | ||||
|    * @param options.end.alt 高度 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    * @param _Dialog {object} 弹框事件 | ||||
|    * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    * */ | ||||
|   constructor(sdk, options, _Dialog = {}) { | ||||
|     super(sdk, options); | ||||
|  | ||||
| @ -22,56 +22,14 @@ class PincerArrowObject extends Base { | ||||
|    * @param sdk  | ||||
|    * @description 双箭头 | ||||
|    * @param options {object} 属性 | ||||
|    * @param options.id {string} 唯一标识 | ||||
|    * @param options.show=true {boolean} 显示/隐藏 | ||||
|    * @param options.name {string} 名称 | ||||
|    * @param options.color='rgba(255, 0, 0, 0.5)' {string} 颜色 | ||||
|    * @param options.color="#ff000080" {string} 颜色 | ||||
|    * @param options.height {number} 高度 | ||||
|    * @param options.heightMode=2{number} 高度模式(0:海拔高度;1:相对地表;2:依附模式) | ||||
|    * @param options.areaUnit='平方米' {string} 面积单位 | ||||
|    * @param options.line {object} 边框 | ||||
|    * @param options.line.width=2 {string} 边框宽 | ||||
|    * @param options.line.color="rgba(155, 155, 124, 0.89)" {string} 边框颜色 | ||||
|    * @param {Array.<object>} options.positions 必填,经纬度和高度的列表,值交替 [{lon,lat,alt},...] | ||||
|    * @param options.positions[].lng {number} 经度 | ||||
|    * @param options.positions[].lat {number} 纬度 | ||||
|    * @param options.positions[].alt {number} 高度 | ||||
|    * @param options.spreadState=false {boolean} 动画 | ||||
|    * @param options.loop=false {loop} 动画重复 | ||||
|    * @param options.spreadTime=3000 {number} 动画持续时长(毫秒) | ||||
|    * @param options.label {object} 标签对象 | ||||
|    * @param options.label.text {string} 标签文本 | ||||
|    * @param options.label.show {string} 标签显隐 | ||||
|    * @param options.label.position {string} 标签位置 | ||||
|    * @param options.label.position {object} 标签位置 | ||||
|    * @param options.label.position.lng {number} 经度 | ||||
|    * @param options.label.position.lat {number} 纬度 | ||||
|    * @param options.label.position.alt {number} 高度 | ||||
|    * @param options.label.fontSize=20 {number} 字体大小 | ||||
|    * @param options.label.fontFamily=0 {number} 字体项 0:黑体;1:思源黑体;2:庞门正道标题体;3:数黑体 | ||||
|    * @param options.label.color=#ffffff {string} 字体颜色 | ||||
|    * @param options.label.lineWidth=4 {number} 引线宽 | ||||
|    * @param options.label.lineColor=#00ffff80 {string} 引线颜色 | ||||
|    * @param options.label.pixelOffset=20 {number} 字体偏移(引线长度) | ||||
|    * @param options.label.backgroundColor=['#00ffff80', '#00ffff80'] {array} 背景颜色 | ||||
|    * @param options.label.scaleByDistance {boolean} 距离缩放 | ||||
|    * @param options.label.near=2000 {number} 视野缩放最近距离 | ||||
|    * @param options.label.far=100000 {number} 视野缩放最远距离 | ||||
|    * @param options.attribute {object} 属性内容 | ||||
|    * @param options.attribute.link={} {object} 链接 | ||||
|    * @param options.attribute.link.content=[]] {array} 链接内容 | ||||
|    * @param options.attribute.link.content[].name {string} 链接名称 | ||||
|    * @param options.attribute.link.content[].url {string} 链接地址 | ||||
|    * @param options.richTextContent {string} 富文本内容 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    * @param {Array.<object>} options.positions 坐标数组 [{lon,lat,alt},...] | ||||
|    * @param _Dialog {object} 弹框事件 | ||||
|    * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    * */ | ||||
|   constructor(sdk, options = {}, _Dialog = {}) { | ||||
|     super(sdk, options); | ||||
|  | ||||
| @ -19,8 +19,8 @@ import { setActiveViewer, closeRotateAround, closeViewFollow } from '../../../Gl | ||||
| class PolygonObject extends Base { | ||||
|   /** | ||||
|    * @constructor | ||||
|    * @description 多边形 | ||||
|    * @param sdk | ||||
|    * @description 多边形 | ||||
|    * @param options {object} 属性 | ||||
|    * @param options.id {string} 唯一标识 | ||||
|    * @param options.show=true {boolean} 显示/隐藏 | ||||
| @ -28,51 +28,11 @@ class PolygonObject extends Base { | ||||
|    * @param options.color='rgba(255, 0, 0, 0.5)' {string} 颜色 | ||||
|    * @param options.height {number} 高度 | ||||
|    * @param options.heightMode=2{number} 高度模式(0:海拔高度;1:相对地表;2:依附模式) | ||||
|    * @param options.areaUnit='平方米' {string} 面积单位 | ||||
|    * @param options.line {object} 边框 | ||||
|    * @param options.line.width=2 {string} 边框宽 | ||||
|    * @param options.line.color="rgba(155, 155, 124, 0.89)" {string} 边框颜色 | ||||
|    * @param {Array.<object>} options.positions 必填,经纬度和高度的列表,值交替 [{lon,lat,alt},...] | ||||
|    * @param options.positions[].lng {number} 经度 | ||||
|    * @param options.positions[].lat {number} 纬度 | ||||
|    * @param options.positions[].alt {number} 高度 | ||||
|    * @param options.label {object} 标签对象 | ||||
|    * @param options.label.text {string} 标签文本 | ||||
|    * @param options.label.show {string} 标签显隐 | ||||
|    * @param options.label.position {string} 标签位置 | ||||
|    * @param options.label.position {object} 标签位置 | ||||
|    * @param options.label.position.lng {number} 经度 | ||||
|    * @param options.label.position.lat {number} 纬度 | ||||
|    * @param options.label.position.alt {number} 高度 | ||||
|    * @param options.label.fontSize=20 {number} 字体大小 | ||||
|    * @param options.label.fontFamily=0 {number} 字体项 0:黑体;1:思源黑体;2:庞门正道标题体;3:数黑体 | ||||
|    * @param options.label.color=#ffffff {string} 字体颜色 | ||||
|    * @param options.label.lineWidth=4 {number} 引线宽 | ||||
|    * @param options.label.lineColor=#00ffff80 {string} 引线颜色 | ||||
|    * @param options.label.pixelOffset=20 {number} 字体偏移(引线长度) | ||||
|    * @param options.label.backgroundColor=['#00ffff80', '#00ffff80'] {array} 背景颜色 | ||||
|    * @param options.label.scaleByDistance {boolean} 距离缩放 | ||||
|    * @param options.label.near=2000 {number} 视野缩放最近距离 | ||||
|    * @param options.label.far=100000 {number} 视野缩放最远距离 | ||||
|    * @param options.attribute {object} 属性内容 | ||||
|    * @param {object} options.attribute.link={} 链接 | ||||
|    * @param options.attribute.link.content=[]] {array} 链接内容 | ||||
|    * @param options.attribute.link.content[].name {string} 链接名称 | ||||
|    * @param options.attribute.link.content[].url {string} 链接地址 | ||||
|    * @param options.richTextContent {string} 富文本内容 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    *  | ||||
|  | ||||
|  | ||||
|    *  | ||||
|    * @param {Array.<object>} options.positions 经纬度和高度的列表,值交替 [{lon,lat,alt},...] | ||||
|     | ||||
|    * @param _Dialog {object} 弹框事件 | ||||
|    * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    * */ | ||||
|  | ||||
| @ -26,44 +26,9 @@ class PolyhedronObject extends Base { | ||||
|    * @param options.name {string} 名称 | ||||
|    * @param options.color="#ff0000" {string} 颜色 | ||||
|    * @param options.height=10 {number} 高 | ||||
|    * @param options.areaUnit='平方米' {string} 投影面积单位 | ||||
|    * @param {Array.<object>} options.positions 必填,经纬度和高度的列表,值交替 [{lon,lat,alt},...] | ||||
|    * @param options.positions[].lng {number} 经度 | ||||
|    * @param options.positions[].lat {number} 纬度 | ||||
|    * @param options.positions[].alt {number} 高度 | ||||
|    * @param options.label {object} 标签对象 | ||||
|    * @param options.label.text {string} 标签文本 | ||||
|    * @param options.label.show {string} 标签显隐 | ||||
|    * @param options.label.position {string} 标签位置 | ||||
|    * @param options.label.position {object} 标签位置 | ||||
|    * @param options.label.position.lng {number} 经度 | ||||
|    * @param options.label.position.lat {number} 纬度 | ||||
|    * @param options.label.position.alt {number} 高度 | ||||
|    * @param options.label.fontSize=20 {number} 字体大小 | ||||
|    * @param options.label.fontFamily=0 {number} 字体项 0:黑体;1:思源黑体;2:庞门正道标题体;3:数黑体 | ||||
|    * @param options.label.color=#ffffff {string} 字体颜色 | ||||
|    * @param options.label.lineWidth=4 {number} 引线宽 | ||||
|    * @param options.label.lineColor=#00ffff80 {string} 引线颜色 | ||||
|    * @param options.label.pixelOffset=20 {number} 字体偏移(引线长度) | ||||
|    * @param options.label.backgroundColor=['#00ffff80', '#00ffff80'] {array} 背景颜色 | ||||
|    * @param options.label.scaleByDistance {boolean} 距离缩放 | ||||
|    * @param options.label.near=2000 {number} 视野缩放最近距离 | ||||
|    * @param options.label.far=100000 {number} 视野缩放最远距离 | ||||
|    * @param options.attribute {object} 属性内容 | ||||
|    * @param {object} options.attribute.link={} 链接 | ||||
|    * @param options.attribute.link.content=[]] {array} 链接内容 | ||||
|    * @param options.attribute.link.content[].name {string} 链接名称 | ||||
|    * @param options.attribute.link.content[].url {string} 链接地址 | ||||
|    * @param options.richTextContent {string} 富文本内容 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    * @param {Array.<object>} options.positions 经纬度和高度的列表,值交替 [{lon,lat,alt},...] | ||||
|    * @param _Dialog {object} 弹框事件 | ||||
|    * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    * */ | ||||
|   constructor(sdk, options = {}, _Dialog = {}) { | ||||
|     super(sdk, options); | ||||
|  | ||||
| @ -25,46 +25,28 @@ class PolylineObject extends Base { | ||||
|    * @description 折线 | ||||
|    * @param options {object} 线属性 | ||||
|    * @param options.name{string} 名称 | ||||
|    * @param options.width=3{number} 线宽 | ||||
|    * @param options.width   * @param options.width=3{number} 线宽 | ||||
|    * @param options.color=#ff0000 {string} 颜色 | ||||
|    * @param options.type=0 {number} 材质类型 0-实线 1-虚线 2-泛光... | ||||
|    * @param options.type=0 {number} 材质类型 0-实线 1-虚线 2-泛光 | ||||
|    * @param options.heightMode=2{number} 高度模式(0:海拔高度;1:相对高度;2:依附模式) | ||||
|    * @param options.noseToTail=false {boolean} 首尾相连 | ||||
|    * @param options['nose-to-tail']=false {boolean} 首尾相连 | ||||
|    * @param options.smooth=false {boolean} 线段圆滑 | ||||
|    * @param options.extend=false {boolean} 线缓冲 | ||||
|    * @param options.extendWidth=10 {number} 线缓冲宽度 | ||||
|    * @param options.extendColor=rgba(255,255,80,0.3) {number} 线缓冲颜色 | ||||
|    * @param options['extend-width']=10 {number} 线缓冲宽度 | ||||
|    * @param options['extend-color']=rgba(255,255,80,0.3) {number} 线缓冲颜色 | ||||
|    * @param options.show=true {boolean} 显隐 | ||||
|    * @param {Array.<object>} options.positions 必填,经纬度和高度的列表,值交替 [{lon,lat,alt},...] | ||||
|    * @param options.positions[].lng {number} 经度 | ||||
|    * @param options.positions[].lat {number} 纬度 | ||||
|    * @param options.positions[].alt {number} 高度 | ||||
|    * @param options.label {object} 标签对象 | ||||
|    * @param options.label.text {string} 标签文本 | ||||
|    * @param options.label.show {string} 标签显隐 | ||||
|    * @param options.label.position {string} 标签位置 | ||||
|    * @param options.label.position {object} 标签位置 | ||||
|    * @param options.label.position.lng {number} 经度 | ||||
|    * @param options.label.position.lat {number} 纬度 | ||||
|    * @param options.label.position.alt {number} 高度 | ||||
|    * @param options.label.fontSize=20 {number} 字体大小 | ||||
|    * @param options.label.fontFamily=0 {number} 字体项 0:黑体;1:思源黑体;2:庞门正道标题体;3:数黑体 | ||||
|    * @param options.label.color=#ffffff {string} 字体颜色 | ||||
|    * @param options.label.lineWidth=4 {number} 引线宽 | ||||
|    * @param options.label.lineColor=#00ffff80 {string} 引线颜色 | ||||
|    * @param options.label.pixelOffset=20 {number} 字体偏移(引线长度) | ||||
|    * @param options.label.backgroundColor=['#00ffff80', '#00ffff80'] {array} 背景颜色 | ||||
|    * @param options.label.scaleByDistance {boolean} 距离缩放 | ||||
|    * @param options.label.near=2000 {number} 视野缩放最近距离 | ||||
|    * @param options.label.far=100000 {number} 视野缩放最远距离 | ||||
|    * @param options.attribute {object} 属性内容 | ||||
|    * @param options.attribute.link={} {string} 链接 | ||||
|    * @param options.attribute.link.content=[]] {array} 链接内容 | ||||
|    * @param options.attribute.link.content[].name {string} 链接名称 | ||||
|    * @param options.attribute.link.content[].url {string} 链接地址 | ||||
|    * @param options.richTextContent {string} 富文本内容 | ||||
|    *  | ||||
|    *  | ||||
|    * @param {Array.<object>} options.positions 坐标数组 [{lng,lat},...] | ||||
|    * @param options.label {object} 标注 | ||||
|    * @param options.label.show=false {boolean} 标注显隐 | ||||
|    * @param options.label.fontSize=20 {number} 标注字体大小 | ||||
|    * @param options.label.color=#ffffff {string} 标注字体颜色 | ||||
|    * @param options.label.lineWidth=1 {number} 标注引线宽 | ||||
|    * @param options.label.pixelOffset=20 {string} 标注引线长度 | ||||
|    * @param options.label.backgroundColor=['#42c6ef', '#42c6ef'] {Array} 标注背景 | ||||
|    * @param options.label.lineColor=#fff000 {string} 标注引线颜色 | ||||
|    * @param options.label.scaleByDistance=false {boolean} 标注是否随视野缩放 | ||||
|    * @param options.label.near=2000 {boolean} 标注随视野缩放最近距离 | ||||
|    * @param options.label.far=100000 {boolean} 标注随视野缩放最远距离 | ||||
|    * @param _Dialog {object} 弹框事件 | ||||
|    * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    * */ | ||||
|  | ||||
| @ -20,44 +20,14 @@ class RadarScan extends Base { | ||||
|    * @param sdk  | ||||
|    * @param options {object} 圆属性 | ||||
|    * @param options.id {string} 标注id | ||||
|    * @param options.show=true {boolean} 显示/隐藏 | ||||
|    * @param [options.show=true] {boolean} 显示/隐藏 | ||||
|    * @param options.lng {number} 经度 | ||||
|    * @param options.lat {number} 维度 | ||||
|    * @param options.color=#FFEB3B {string} 颜色 | ||||
|    * @param options.color=#1FA8E3 {string} 颜色 | ||||
|    * @param options.radius=10 {number} 半径 | ||||
|    * @param options.speed=20 {number} 速度 | ||||
|    * @param options.label {object} 标签对象 | ||||
|    * @param options.label.show {string} 标签显隐 | ||||
|    * @param options.label.position {string} 标签位置 | ||||
|    * @param options.label.position {object} 标签位置 | ||||
|    * @param options.label.position.lng {number} 经度 | ||||
|    * @param options.label.position.lat {number} 纬度 | ||||
|    * @param options.label.position.alt {number} 高度 | ||||
|    * @param options.label.fontSize=20 {number} 字体大小 | ||||
|    * @param options.label.fontFamily=0 {number} 字体项 0:黑体;1:思源黑体;2:庞门正道标题体;3:数黑体 | ||||
|    * @param options.label.color=#ffffff {string} 字体颜色 | ||||
|    * @param options.label.lineWidth=4 {number} 引线宽 | ||||
|    * @param options.label.lineColor=#00ffff80 {string} 引线颜色 | ||||
|    * @param options.label.pixelOffset=20 {number} 字体偏移(引线长度) | ||||
|    * @param options.label.backgroundColor=['#00ffff80', '#00ffff80'] {array} 背景颜色 | ||||
|    * @param options.label.scaleByDistance {boolean} 距离缩放 | ||||
|    * @param options.label.near=2000 {number} 视野缩放最近距离 | ||||
|    * @param options.label.far=100000 {number} 视野缩放最远距离 | ||||
|    * @param options.attribute {object} 属性内容 | ||||
|    * @param {object} options.attribute.link={} 链接 | ||||
|    * @param options.attribute.link.content=[]] {array} 链接内容 | ||||
|    * @param options.attribute.link.content[].name {string} 链接名称 | ||||
|    * @param options.attribute.link.content[].url {string} 链接地址 | ||||
|    * @param options.richTextContent {string} 富文本内容 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    * @param _Dialog {object} 弹框事件 | ||||
|    * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    */ | ||||
|   constructor(sdk, options = {}, _Dialog = {}) { | ||||
|     super(sdk, options); | ||||
|  | ||||
| @ -23,46 +23,16 @@ class RadarScanStereoscopic extends Base { | ||||
|    * @param sdk  | ||||
|    * @param options {object} 属性 | ||||
|    * @param options.id {string} 标注id | ||||
|    * @param options.show=true {boolean} 显示/隐藏 | ||||
|    * @param [options.show=true] {boolean} 显示/隐藏 | ||||
|    * @param options.lng {number} 经度 | ||||
|    * @param options.lat {number} 纬度 | ||||
|    * @param options.alt {number} 高度 | ||||
|    * @param options.colorOut=rgba(255,255,0,0.3){string} 范围颜色 | ||||
|    * @param options.colorIn=rgba(255,0,0,0.3){string} 扫描颜色 | ||||
|    * @param options.colorOut=#ff0000 {string} 范围颜色 | ||||
|    * @param options.colorIn=#ff0000 {string} 扫描颜色 | ||||
|    * @param options.radius=10 {number} 半径 | ||||
|    * @param options.duration=2000 {number} 持续时间 | ||||
|    * @param options.label {object} 标签对象 | ||||
|    * @param options.label.show {string} 标签显隐 | ||||
|    * @param options.label.position {string} 标签位置 | ||||
|    * @param options.label.position {object} 标签位置 | ||||
|    * @param options.label.position.lng {number} 经度 | ||||
|    * @param options.label.position.lat {number} 纬度 | ||||
|    * @param options.label.position.alt {number} 高度 | ||||
|    * @param options.label.fontSize=20 {number} 字体大小 | ||||
|    * @param options.label.fontFamily=0 {number} 字体项 0:黑体;1:思源黑体;2:庞门正道标题体;3:数黑体 | ||||
|    * @param options.label.color=#ffffff {string} 字体颜色 | ||||
|    * @param options.label.lineWidth=4 {number} 引线宽 | ||||
|    * @param options.label.lineColor=#00ffff80 {string} 引线颜色 | ||||
|    * @param options.label.pixelOffset=20 {number} 字体偏移(引线长度) | ||||
|    * @param options.label.backgroundColor=['#00ffff80', '#00ffff80'] {array} 背景颜色 | ||||
|    * @param options.label.scaleByDistance {boolean} 距离缩放 | ||||
|    * @param options.label.near=2000 {number} 视野缩放最近距离 | ||||
|    * @param options.label.far=100000 {number} 视野缩放最远距离 | ||||
|    * @param options.attribute {object} 属性内容 | ||||
|    * @param {object} options.attribute.link={} 链接 | ||||
|    * @param options.attribute.link.content=[]] {array} 链接内容 | ||||
|    * @param options.attribute.link.content[].name {string} 链接名称 | ||||
|    * @param options.attribute.link.content[].url {string} 链接地址 | ||||
|    * @param options.richTextContent {string} 富文本内容 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    * @param _Dialog {object} 弹框事件 | ||||
|    * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    */ | ||||
|   constructor(sdk, options, _Dialog = {}) { | ||||
|     super(sdk, options); | ||||
|  | ||||
| @ -19,56 +19,22 @@ class SectorObject extends Base { | ||||
|   /** | ||||
|    * @constructor | ||||
|    * @description 创建扇形 | ||||
|    * @param sdk | ||||
|    * @param options {object} 扇形属性 | ||||
|    * @param options.id {string} 标注id | ||||
|    * @param options.name {string} 名称 | ||||
|    * @param options.show=true {boolean} 显示/隐藏 | ||||
|    * @param options.color="rgba(255, 0, 0, 0.5)" {string} 颜色 | ||||
|    * @param options.center {object} 位置 | ||||
|    * @param options.center.lng {number} 经度 | ||||
|    * @param options.center.lat {number} 纬度 | ||||
|    * @param options.center.alt {number} 高度 | ||||
|    * @param options.center.lng {object} 经度 | ||||
|    * @param options.center.lat {object} 维度 | ||||
|    * @param options.radius=10 {number} 半径 | ||||
|    * @param options.startAngle=10 {number} 起始方向 | ||||
|    * @param options.endAngle=0 {number} 结束方向 | ||||
|    * @param options.line {object} 边框 | ||||
|    * @param options.line.width=3 {number} 边框宽 | ||||
|    * @param options.line.width=3 {string} 边框宽 | ||||
|    * @param options.line.color="rgba(155, 155, 124, 0.89)" {string} 边框颜色 | ||||
|    * @param options.label {object} 标注 | ||||
|    * @param options.heightMode=2{number} 高度模式(0:海拔高度;1:相对地表;2:依附模式) | ||||
|    * @param options.areaUnit='平方米' {string} 面积单位 | ||||
|    * @param options.label {object} 标签对象 | ||||
|    * @param options.label.text {string} 标签文本 | ||||
|    * @param options.label.show {string} 标签显隐 | ||||
|    * @param options.label.position {string} 标签位置 | ||||
|    * @param options.label.position.lng {number} 经度 | ||||
|    * @param options.label.position.lat {number} 纬度 | ||||
|    * @param options.label.position.alt {number} 高度 | ||||
|    * @param options.label.fontSize=20 {number} 字体大小 | ||||
|    * @param options.label.fontFamily=0 {number} 字体项 0:黑体;1:思源黑体;2:庞门正道标题体;3:数黑体 | ||||
|    * @param options.label.color=#ffffff {string} 字体颜色 | ||||
|    * @param options.label.lineWidth=4 {number} 引线宽 | ||||
|    * @param options.label.lineColor=#00ffff80 {string} 引线颜色 | ||||
|    * @param options.label.pixelOffset=20 {number} 字体偏移(引线长度) | ||||
|    * @param options.label.backgroundColor=['#00ffff80', '#00ffff80'] {array} 背景颜色 | ||||
|    * @param options.label.scaleByDistance {boolean} 距离缩放 | ||||
|    * @param options.label.near=2000 {number} 视野缩放最近距离 | ||||
|    * @param options.label.far=100000 {number} 视野缩放最远距离 | ||||
|    * @param options.attribute {object} 属性内容 | ||||
|    * @param options.attribute.link {object} 链接 | ||||
|    * @param options.attribute.link.content=[]] {array} 链接内容 | ||||
|    * @param options.attribute.link.content[].name {string} 链接名称 | ||||
|    * @param options.attribute.link.content[].url {string} 链接地址 | ||||
|    * @param options.richTextContent {string} 富文本内容 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    */ | ||||
|   constructor(sdk, options = {}) { | ||||
|     super(sdk, options); | ||||
|  | ||||
| @ -22,56 +22,14 @@ class StraightArrowObject extends Base { | ||||
|    * @param sdk | ||||
|    * @description 直线箭头 | ||||
|    * @param options {object} 属性 | ||||
|    * @param options.id {string} 唯一标识 | ||||
|    * @param options.show=true {boolean} 显示/隐藏 | ||||
|    * @param options.name {string} 名称 | ||||
|    * @param options.color='rgba(255, 0, 0, 0.5)' {string} 颜色 | ||||
|    * @param options.color="#ff000080" {string} 颜色 | ||||
|    * @param options.height {number} 高度 | ||||
|    * @param options.heightMode=2{number} 高度模式(0:海拔高度;1:相对地表;2:依附模式) | ||||
|    * @param options.areaUnit='平方米' {string} 面积单位 | ||||
|    * @param options.line {object} 边框 | ||||
|    * @param options.line.width=2 {string} 边框宽 | ||||
|    * @param options.line.color="rgba(155, 155, 124, 0.89)" {string} 边框颜色 | ||||
|    * @param {Array.<object>} options.positions 必填,经纬度和高度的列表,值交替 [{lon,lat,alt},...] | ||||
|    * @param options.positions[].lng {number} 经度 | ||||
|    * @param options.positions[].lat {number} 纬度 | ||||
|    * @param options.positions[].alt {number} 高度 | ||||
|    * @param options.spreadState=false {boolean} 动画 | ||||
|    * @param options.loop=false {loop} 动画重复 | ||||
|    * @param options.spreadTime=3000 {number} 动画持续时长(毫秒) | ||||
|    * @param options.label {object} 标签对象 | ||||
|    * @param options.label.text {string} 标签文本 | ||||
|    * @param options.label.show {string} 标签显隐 | ||||
|    * @param options.label.position {string} 标签位置 | ||||
|    * @param options.label.position {object} 标签位置 | ||||
|    * @param options.label.position.lng {number} 经度 | ||||
|    * @param options.label.position.lat {number} 纬度 | ||||
|    * @param options.label.position.alt {number} 高度 | ||||
|    * @param options.label.fontSize=20 {number} 字体大小 | ||||
|    * @param options.label.fontFamily=0 {number} 字体项 0:黑体;1:思源黑体;2:庞门正道标题体;3:数黑体 | ||||
|    * @param options.label.color=#ffffff {string} 字体颜色 | ||||
|    * @param options.label.lineWidth=4 {number} 引线宽 | ||||
|    * @param options.label.lineColor=#00ffff80 {string} 引线颜色 | ||||
|    * @param options.label.pixelOffset=20 {number} 字体偏移(引线长度) | ||||
|    * @param options.label.backgroundColor=['#00ffff80', '#00ffff80'] {array} 背景颜色 | ||||
|    * @param options.label.scaleByDistance {boolean} 距离缩放 | ||||
|    * @param options.label.near=2000 {number} 视野缩放最近距离 | ||||
|    * @param options.label.far=100000 {number} 视野缩放最远距离 | ||||
|    * @param options.attribute {object} 属性内容 | ||||
|    * @param options.attribute.link={} {object} 链接 | ||||
|    * @param options.attribute.link.content=[]] {array} 链接内容 | ||||
|    * @param options.attribute.link.content[].name {string} 链接名称 | ||||
|    * @param options.attribute.link.content[].url {string} 链接地址 | ||||
|    * @param options.richTextContent {string} 富文本内容 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    * @param {Array.<object>} options.positions 坐标数组 [{lon,lat,alt},...] | ||||
|    * @param _Dialog {object} 弹框事件 | ||||
|    * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    * */ | ||||
|   constructor(sdk, options = {}, _Dialog = {}) { | ||||
|     super(sdk, options); | ||||
|  | ||||
| @ -33,7 +33,7 @@ class TextBox extends Base { | ||||
|  | ||||
|     this.callback = callback | ||||
|  | ||||
|     // syncData(this.sdk, this.options.id) | ||||
|     syncData(this.sdk, this.options.id) | ||||
|  | ||||
|   } | ||||
|  | ||||
| @ -134,15 +134,17 @@ class TextBox extends Base { | ||||
|   } | ||||
|   async getwords(words) { | ||||
|     this.options.text = words | ||||
|     this.callback(this.options) | ||||
|  | ||||
|     let { sdkP } = getSdk() | ||||
|     if (this.sdk === sdkP && sdkP) {//三维 | ||||
|       this.callback(this.options) | ||||
|       syncData(this.sdk, this.options.id) | ||||
|     } | ||||
|     else if (sdkP) {//二维 | ||||
|       sdkP.entityMap.get(this.options.id).text = words | ||||
|       sdkP.entityMap.get(this.options.id).twoToThree(this.options.position) | ||||
|     } else if (!sdkP) { | ||||
|       this.callback(this.options) | ||||
|       syncData(this.sdk, this.options.id) | ||||
|     } | ||||
|   } | ||||
| @ -283,6 +285,7 @@ class TextBox extends Base { | ||||
|       this.sdk.viewer.cesiumWidget.container.removeChild(this.textDom); | ||||
|     } | ||||
|     await this.sdk.removeIncetance(this.options.id) | ||||
|     syncData(this.sdk, this.options.id) | ||||
|   } | ||||
|  | ||||
|   flicker() { } | ||||
|  | ||||
| @ -14,27 +14,14 @@ class GroundText extends Base { | ||||
|    * @param sdk | ||||
|    * @description 贴地文字 | ||||
|    * @param options {object} 属性 | ||||
|    * @param options.id {string} 唯一标识 | ||||
|    * @param options.show=true {boolean} 显示/隐藏 | ||||
|    * @param options.text {string} 文字 | ||||
|    * @param options.angle=0 {number} 旋转角度 | ||||
|    * @param options.scale=1 {number} 缩放比例 | ||||
|    * @param options.speed=1 {number} 文字滚动速度 | ||||
|    * @param {object} options.position 位置 | ||||
|    * @param {number} options.position.lng 经度 | ||||
|    * @param {number} options.position.lat 纬度 | ||||
|    * @param {object} options.positions 坐标集[{lon,lat}]仅在未定义 position 时有效 | ||||
|    * @param options.positions[].lng {number} 经度 | ||||
|    * @param options.positions[].lat {number} 纬度 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    * @param options.scale=1 {number} 比例 | ||||
|    * @param {object} options.position 经纬度{lon,lat} | ||||
|    * @param {object} options.positions 经纬度集[{lon,lat}]仅在未定义 position 时有效 | ||||
|    * @param _Dialog {object} 弹框事件 | ||||
|    * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    * */ | ||||
|   constructor(sdk, options = {}, _Dialog = {}) { | ||||
|     super(sdk, options) | ||||
|  | ||||
| @ -16,23 +16,12 @@ class StandText extends Base { | ||||
|    * @param sdk | ||||
|    * @description 立体文字 | ||||
|    * @param options {object} | ||||
|    * @param options.id {string} 唯一标识 | ||||
|    * @param options.text {string} 文字 | ||||
|    * @param options.color="#FFC107" {string} 颜色 | ||||
|    * @param options.speed=1 {number} 文字移动速度 | ||||
|    * @param {Array.<object>} positions 经纬度和高度的列表,值交替 [{lon,lat,alt},...] | ||||
|    * @param options.positions[].lng {number} 经度 | ||||
|    * @param options.positions[].lat {number} 纬度 | ||||
|    * @param options.positions[].alt {number} 高度 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    * @param _Dialog {object} 弹框事件 | ||||
|    * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    * */ | ||||
|   constructor(sdk, options, _Dialog = {}) { | ||||
|     super(sdk, options); | ||||
|  | ||||
| @ -23,9 +23,7 @@ class TrajectoryMotion extends Base { | ||||
|   /** | ||||
|  * @constructor | ||||
|  * @description 轨迹运动 | ||||
|  * @param sdk | ||||
|  * @param options {object} | ||||
|  * @param options.id {string} 唯一标识 | ||||
|  * @param options.name {string} 名称 | ||||
|  * @param options.speed=1 {number} 运行速度 | ||||
|  * @param options.delay=0 {number} 运动延迟时间(毫秒) | ||||
| @ -35,41 +33,22 @@ class TrajectoryMotion extends Base { | ||||
|  * @param options.state=true {boolean} 模型运动 | ||||
|  * @param options.routeDirection=true {boolean} 路径方向 | ||||
|  * @param options.viewFollow=false {boolean} 视角跟随 | ||||
|  * @param options.realTimeRoute=false {boolean} 实时路径 | ||||
|  * @param options.model {object} 模型参数 | ||||
|  * @param options.model.show=true {boolean} 模型显隐 | ||||
|  * @param options.model.url {string} 模型地址 | ||||
|  * @param options.model.url {url} 模型地址 | ||||
|  * @param options.model.pixelSize=70 {number} 模型像素大小 | ||||
|  * @param options.model.heading=0 {number} 模型航向角 | ||||
|  * @param options.model.pitch=0 {number} 模型俯仰角 | ||||
|  * @param options.model.roll=0 {number} 模型翻滚角 | ||||
|  * @param options.model.heading=0 {number}  | ||||
|  * @param options.model.pitch=0 {number}  | ||||
|  * @param options.model.roll=0 {number}  | ||||
|  * @param options.model.scale=1 {number} 模型比例 | ||||
|  * @param options.model.animate {string} 模型动画 | ||||
|  * @param options.line {object} 路径参数 | ||||
|  * @param options.line.show=true {boolean} 路径显隐 | ||||
|  * @param options.line.smooth=false {boolean} 路径圆滑 | ||||
|  * @param options.line.noseToTail=false {boolean} 路径首尾相联 | ||||
|  * @param options.line.noseToTail=false {boolean} 路径收尾相联 | ||||
|  * @param {Array.<object>} options.line.positions 经纬度和高度的列表,值交替 [{lon,lat,alt},...] | ||||
|  * @param options.positions[].lng {number} 经度 | ||||
|  * @param options.positions[].lat {number} 纬度 | ||||
|  * @param options.positions[].alt {number} 高度 | ||||
|  * @param options.label {object} 标签对象 | ||||
|  * @param options.label.show {string} 标签显隐 | ||||
|  * @param options.label.position {string} 标签位置 | ||||
|  * @param options.label.position {object} 标签位置 | ||||
|  * @param options.label.position.lng {number} 经度 | ||||
|  * @param options.label.position.lat {number} 纬度 | ||||
|  * @param options.label.position.alt {number} 高度 | ||||
|  * @param options.label.fontSize=20 {number} 字体大小 | ||||
|  * @param options.label.fontFamily=0 {number} 字体项 0:黑体;1:思源黑体;2:庞门正道标题体;3:数黑体 | ||||
|  * @param options.label.color=#ffffff {string} 字体颜色 | ||||
|  * @param options.label.lineWidth=4 {number} 引线宽 | ||||
|  * @param options.label.lineColor=#00ffff80 {string} 引线颜色 | ||||
|  * @param options.label.pixelOffset=20 {number} 字体偏移(引线长度) | ||||
|  * @param options.label.backgroundColor=['#00ffff80', '#00ffff80'] {array} 背景颜色 | ||||
|  * @param options.label.scaleByDistance {boolean} 距离缩放 | ||||
|  * @param options.label.near=2000 {number} 视野缩放最近距离 | ||||
|  * @param options.label.far=100000 {number} 视野缩放最远距离 | ||||
|  * @param _Dialog {object} 弹框事件 | ||||
|  * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|  * */ | ||||
|   constructor(sdk, options = {}, _Dialog = {}) { | ||||
|     super(sdk, options); | ||||
|  | ||||
| @ -29,47 +29,13 @@ class WallRealStereoscopic extends Base { | ||||
|    * @param options.color="#ffffff" {string} 颜色 | ||||
|    * @param options.width=0.24 {number} 宽 | ||||
|    * @param options.show=true {boolean} 显隐 | ||||
|    * @param options.noseToTail=false {boolean} 首尾相连 | ||||
|    * @param options['nose-to-tail']=false {boolean} 首尾相连 | ||||
|    * @param options.extrudedHeight=2.4 {number} 拉伸高度 | ||||
|    * @param options.cornerType=0 {string} 拐角类型;0:直角;1:斜角;2:圆角 | ||||
|    * @param options.material=0 {number} 材质,0:纯色墙;1:红砖;2:黄砖;3:灰瓷 | ||||
|    * @param {Array.<object>} options.positions 必填,经纬度和高度的列表,值交替 [{lon,lat,alt},...] | ||||
|    * @param options.positions[].lng {number} 经度 | ||||
|    * @param options.positions[].lat {number} 纬度 | ||||
|    * @param options.positions[].alt {number} 高度 | ||||
|    * @param options.label {object} 标签对象 | ||||
|    * @param options.label.text {string} 标签文本 | ||||
|    * @param options.label.show {string} 标签显隐 | ||||
|    * @param options.label.position {string} 标签位置 | ||||
|    * @param options.label.position {object} 标签位置 | ||||
|    * @param options.label.position.lng {number} 经度 | ||||
|    * @param options.label.position.lat {number} 纬度 | ||||
|    * @param options.label.position.alt {number} 高度 | ||||
|    * @param options.label.fontSize=20 {number} 字体大小 | ||||
|    * @param options.label.fontFamily=0 {number} 字体项 0:黑体;1:思源黑体;2:庞门正道标题体;3:数黑体 | ||||
|    * @param options.label.color=#ffffff {string} 字体颜色 | ||||
|    * @param options.label.lineWidth=4 {number} 引线宽 | ||||
|    * @param options.label.lineColor=#00ffff80 {string} 引线颜色 | ||||
|    * @param options.label.pixelOffset=20 {number} 字体偏移(引线长度) | ||||
|    * @param options.label.backgroundColor=['#00ffff80', '#00ffff80'] {array} 背景颜色 | ||||
|    * @param options.label.scaleByDistance {boolean} 距离缩放 | ||||
|    * @param options.label.near=2000 {number} 视野缩放最近距离 | ||||
|    * @param options.label.far=100000 {number} 视野缩放最远距离 | ||||
|    * @param options.attribute {object} 属性内容 | ||||
|    * @param {object} options.attribute.link={} 链接 | ||||
|    * @param options.attribute.link.content=[]] {array} 链接内容 | ||||
|    * @param options.attribute.link.content[].name {string} 链接名称 | ||||
|    * @param options.attribute.link.content[].url {string} 链接地址 | ||||
|    * @param options.richTextContent {string} 富文本内容 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    * @param {Array.<object>} positions 经纬度和高度的列表,值交替 [{lon,lat,alt},...] | ||||
|    * @param _Dialog {object} 弹框事件 | ||||
|    * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    * */ | ||||
|   constructor(sdk, options, _Dialog = {}) { | ||||
|     super(sdk, options); | ||||
|  | ||||
| @ -23,46 +23,12 @@ class WallStereoscopic extends Base { | ||||
|    * @param options.color="#00d9ff" {string} 颜色 | ||||
|    * @param options.show=true {boolean} 显隐 | ||||
|    * @param options.extrudedHeight=2.4 {number} 拉伸高度 | ||||
|    * @param options.noseToTail=false {boolean} 首尾相连 | ||||
|    * @param options['nose-to-tail']=false {boolean} 首尾相连 | ||||
|    * @param options.material=0 {number} 材质,0:纯色墙;1:上升墙;2:箭头墙;3:警戒墙 | ||||
|    * @param options.duration=1000 {number} 持续时间 | ||||
|    * @param {Array.<object>} options.positions 必填,经纬度和高度的列表,值交替 [{lon,lat,alt},...] | ||||
|    * @param options.positions[].lng {number} 经度 | ||||
|    * @param options.positions[].lat {number} 纬度 | ||||
|    * @param options.positions[].alt {number} 高度 | ||||
|    * @param options.label {object} 标签对象 | ||||
|    * @param options.label.text {string} 标签文本 | ||||
|    * @param options.label.show {string} 标签显隐 | ||||
|    * @param options.label.position {string} 标签位置 | ||||
|    * @param options.label.position {object} 标签位置 | ||||
|    * @param options.label.position.lng {number} 经度 | ||||
|    * @param options.label.position.lat {number} 纬度 | ||||
|    * @param options.label.position.alt {number} 高度 | ||||
|    * @param options.label.fontSize=20 {number} 字体大小 | ||||
|    * @param options.label.fontFamily=0 {number} 字体项 0:黑体;1:思源黑体;2:庞门正道标题体;3:数黑体 | ||||
|    * @param options.label.color=#ffffff {string} 字体颜色 | ||||
|    * @param options.label.lineWidth=4 {number} 引线宽 | ||||
|    * @param options.label.lineColor=#00ffff80 {string} 引线颜色 | ||||
|    * @param options.label.pixelOffset=20 {number} 字体偏移(引线长度) | ||||
|    * @param options.label.backgroundColor=['#00ffff80', '#00ffff80'] {array} 背景颜色 | ||||
|    * @param options.label.scaleByDistance {boolean} 距离缩放 | ||||
|    * @param options.label.near=2000 {number} 视野缩放最近距离 | ||||
|    * @param options.label.far=100000 {number} 视野缩放最远距离 | ||||
|    * @param options.attribute {object} 属性内容 | ||||
|    * @param {object} options.attribute.link={} 链接 | ||||
|    * @param options.attribute.link.content=[]] {array} 链接内容 | ||||
|    * @param options.attribute.link.content[].name {string} 链接名称 | ||||
|    * @param options.attribute.link.content[].url {string} 链接地址 | ||||
|    * @param options.richTextContent {string} 富文本内容 | ||||
|    * @param options.customView {object} 默认视角 | ||||
|    * @param options.customView.orientation {object} 默认视角方位 | ||||
|    * @param options.customView.orientation.heading {number} 航向角 | ||||
|    * @param options.customView.orientation.pitch {number} 俯仰角 | ||||
|    * @param options.customView.orientation.roll {number} 翻滚角 | ||||
|    * @param options.customView.relativePosition {object} 视角相对位置 | ||||
|    * @param options.customView.relativePosition.lng {number} 经度 | ||||
|    * @param options.customView.relativePosition.lat {number} 纬度 | ||||
|    * @param options.customView.relativePosition.alt {number} 高度 | ||||
|    * @param {Array.<object>} positions 经纬度和高度的列表,值交替 [{lon,lat,alt},...] | ||||
|    * @param _Dialog {object} 弹框事件 | ||||
|    * @param _Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    * */ | ||||
|   constructor(sdk, options, _Dialog = {}) { | ||||
|     super(sdk, options); | ||||
|  | ||||
| @ -15,17 +15,14 @@ class WaterSurface extends Base { | ||||
|    * @param sdk  | ||||
|    * @description 水面 | ||||
|    * @param options {object} 面属性 | ||||
|    * @param options.id {string} 唯一标识 | ||||
|    * @param options.show=true {boolean} 显隐 | ||||
|    * @param options.name=未命名对象 {string} 名称 | ||||
|    * @param {Array.<object>} options.positions 坐标列表 | ||||
|    * @param options.positions[].lng {number} 经度 | ||||
|    * @param options.positions[].lat {number} 纬度 | ||||
|    * @param options.positions[].alt {number} 高度 | ||||
|    * @param options.positions {Array.<{lng:number, lat:number, alt:number}>} 坐标数组 | ||||
|    * @param options.color=rgba(32,67,135,0.5) {string} 颜色 | ||||
|    * @param options.frequency=10 {number} 频率 | ||||
|    * @param options.animationSpeed=1 {number} 动画速度 | ||||
|    * @param options.frequency=100 {number} 频率 | ||||
|    * @param options.animationSpeed=0.02 {number} 动画速度 | ||||
|    * @param options.amplitude=10 {number} 振幅 | ||||
|    * @param Dialog {object} 弹框对象 | ||||
|    * @param Dialog.confirmCallBack {function} 弹框确认时的回调 | ||||
|    * */ | ||||
|   constructor(sdk, options = {}, _Dialog = {}) { | ||||
|     super(sdk, options); | ||||
|  | ||||
| @ -443,8 +443,14 @@ class YJEarth { | ||||
|           _this.entityMap.get(_this.clickTextDom.id).isClick(movement.position, _this.clickTextDom.id) | ||||
|  | ||||
|           _this.blurFun = () => { | ||||
|             _this.entityMap.get(_this.clickTextDom.id).isClick((movement && movement.position) || null, _this.clickTextDom.id) | ||||
|             // let { sdkP } = getSdk() | ||||
|             // if (_this == sdkP && sdkP) {//二维 | ||||
|             //   _this.entityMap.get(_this.clickTextDom.id).getwords(_this.clickTextDom.getElementsByTagName('textarea')[0].value) | ||||
|             // } else if (!sdkP) { | ||||
|             _this.entityMap.get(_this.clickTextDom.id).getwords(_this.clickTextDom.getElementsByTagName('textarea')[0].value) | ||||
|             // } | ||||
|  | ||||
|             _this.clickTextDom.querySelector('textarea').removeEventListener('blur', _this.blurFun) | ||||
|           } | ||||
|           _this.clickTextDom.querySelector('textarea').addEventListener('blur', _this.blurFun) | ||||
|           break; | ||||
| @ -501,7 +507,7 @@ class YJEarth { | ||||
|         _this.clickTextDom.removeEventListener('mousedown', mousedown); | ||||
|         _this.viewer._element.removeEventListener('mousemove', mousemove); | ||||
|         _this.viewer._element.removeEventListener('mouseup', mouseup); | ||||
|         _this.entityMap.get(_this.clickTextDom.id).getwords(_this.clickTextDom.getElementsByTagName('textarea')[0].value) | ||||
|         // _this.entityMap.get(_this.clickTextDom.id).getwords(_this.clickTextDom.getElementsByTagName('textarea')[0].value) | ||||
|  | ||||
|         _this.clickTextDom.style['pointer-events'] = 'none' | ||||
|         _this.clickTextDom = undefined | ||||
|  | ||||
		Reference in New Issue
	
	Block a user