| | |
| | | |
| | | // /** |
| | | // * Cesium库 |
| | | // */ |
| | | // declare namespace Cesium{ |
| | | |
| | | // } |
| | | |
| | | /** |
| | | * 国内偏移坐标系 枚举 |
| | | */ |
| | |
| | | * 百度(BD09) 偏移坐标系 |
| | | */ |
| | | BAIDU = "BD09" |
| | | } |
| | | |
| | | /** |
| | | * 裁剪模型类型 |
| | | */ |
| | | declare const enum ClipType { |
| | | /** |
| | | * z水平面, 切底部 |
| | | */ |
| | | Z = 1, |
| | | /** |
| | | * z水平面,切顶部 |
| | | */ |
| | | ZR = 2, |
| | | /** |
| | | * x垂直面,切西向 |
| | | */ |
| | | X = 3, |
| | | /** |
| | | * x垂直面,切东向 |
| | | */ |
| | | XR = 4, |
| | | /** |
| | | * y垂直面, 切南向 |
| | | */ |
| | | Y = 5, |
| | | /** |
| | | * y垂直面,切北向 |
| | | */ |
| | | YR = 6 |
| | | } |
| | | |
| | | /** |
| | |
| | | * tooltip弹窗关闭 |
| | | */ |
| | | tooltipClose = "tooltipClose", |
| | | /** |
| | | * highlight高亮后 |
| | | */ |
| | | highlightOpen = "highlightOpen", |
| | | /** |
| | | * highlight关闭后 |
| | | */ |
| | | highlightClose = "highlightClose", |
| | | /** |
| | | * 左键单击 鼠标事件 |
| | | */ |
| | |
| | | * 通用:图片 材质2 (没有加载完成前的白色闪烁,但也不支持纯白色的图片) |
| | | * @property image - 图片对象或图片地址 |
| | | * @property [opacity = 1.0] - 透明度 |
| | | * @property [options.color = Cesium.Color.WHITE] - 颜色 |
| | | */ |
| | | const Image2: string; |
| | | /** |
| | |
| | | * @property [speed = 2] - 速度,值越大越快 |
| | | * @property [percent = 0.04] - 比例 |
| | | * @property [alpha = 0.1] - 透明程度 0.0-1.0 |
| | | * @property [startTime = 0] - 开始的时间 |
| | | */ |
| | | const LineFlowColor: string; |
| | | /** |
| | |
| | | } |
| | | |
| | | /** |
| | | * 相机旋转的类型 |
| | | */ |
| | | declare const enum MoveType { |
| | | /** |
| | | * 向屏幕中心靠近 |
| | | */ |
| | | ENLARGE = 0, |
| | | /** |
| | | * 向屏幕中心远离 |
| | | */ |
| | | NARROW = 1, |
| | | /** |
| | | * 相机原地左旋转 |
| | | */ |
| | | LEFT_ROTATE = 2, |
| | | /** |
| | | * 相机原地右旋转 |
| | | */ |
| | | RIGHT_ROTATE = 3, |
| | | /** |
| | | * 相机原地上旋转 |
| | | */ |
| | | TOP_ROTATE = 4, |
| | | /** |
| | | * 相机原地下旋转 |
| | | */ |
| | | BOTTOM_ROTATE = 5 |
| | | } |
| | | |
| | | /** |
| | | * 状态 枚举 |
| | | */ |
| | | declare const enum State { |
| | |
| | | constructor(options: { |
| | | id?: string | number; |
| | | enabled?: boolean; |
| | | insertIndex?: Int; |
| | | insertIndex?: number; |
| | | insertBefore?: HTMLElement; |
| | | }); |
| | | /** |
| | |
| | | enabled?: boolean; |
| | | fps?: boolean; |
| | | latDecimal?: number; |
| | | template?: Sring | Sring[]; |
| | | template?: string | String[]; |
| | | crs?: string | CRS; |
| | | crsDecimal?: number; |
| | | cacheTime?: number; |
| | |
| | | * @param [options.id = uuid()] - 对象的id标识 |
| | | * @param [options.enabled = true] - 对象的启用状态 |
| | | * @param [options.leftLayer] - 左侧区域瓦片图层 |
| | | * @param [options.leftLayer] - 右侧区域瓦片图层 |
| | | * @param [options.rightLayer] - 右侧区域瓦片图层 |
| | | */ |
| | | declare class MapSplit extends BaseControl { |
| | | constructor(options: { |
| | | id?: string | number; |
| | | enabled?: boolean; |
| | | leftLayer?: BaseTileLayer; |
| | | leftLayer?: BaseTileLayer; |
| | | rightLayer?: BaseTileLayer; |
| | | }); |
| | | /** |
| | | * 左侧区域瓦片图层 |
| | |
| | | hasEventParent(obj: any): this; |
| | | } |
| | | |
| | | /** |
| | | * 转换options参数处理基类 |
| | | * @param options - 参数名称 |
| | | */ |
| | | declare class BaseOptsConver { |
| | | constructor(options: any); |
| | | } |
| | | |
| | | declare namespace BaseThing { |
| | | /** |
| | | * 当前类支持的{@link EventType}事件类型 |
| | |
| | | */ |
| | | static parse(position: string | any[] | any | Cesium.Cartesian3 | any, time?: Cesium.JulianDate): LatLngPoint; |
| | | /** |
| | | * 根据传入的各种对象数据,转换返回Cartesian3对象 |
| | | * @param position - 坐标位置 |
| | | * @param [time = Cesium.JulianDate.now()] - Cesium坐标时,getValue传入的时间值 |
| | | * @returns 转换返回的Cartesian3对象 |
| | | */ |
| | | static parseCartesian3(position: string | any[] | any | Cesium.Cartesian3 | any, time?: Cesium.JulianDate): Cesium.Cartesian3; |
| | | /** |
| | | * 根据数组数据,转换返回LatLngPoint对象 |
| | | * 示例:[113.123456,31.123456,30.1] |
| | | * @param arr - 坐标位置 |
| | |
| | | * 高度的格式化时的长度,默认为1 |
| | | */ |
| | | static FormatAltLength: number; |
| | | } |
| | | |
| | | /** |
| | | * 局部坐标系 与 世界坐标系 转换 |
| | | * @param center - 局部坐标的中心点对应的世界坐标 |
| | | * @param fixedFrameTransform - 局部坐标系的轴方向 |
| | | */ |
| | | declare class LocalWorldTransform { |
| | | constructor(center: Cesium.Cartesian3, fixedFrameTransform: Cesium.Transforms.LocalFrameToFixedFrame); |
| | | /** |
| | | * 局部坐标 转换成对应的 世界坐标 |
| | | * @param localPoint - 局部坐标 |
| | | * @param result - 世界坐标 |
| | | * @returns 世界坐标 |
| | | */ |
| | | localToWorld(localPoint: Cesium.Cartesian3, result: Cesium.Cartesian3): Cesium.Cartesian3; |
| | | /** |
| | | * 世界坐标 转换成对应的 局部坐标 |
| | | * @param worldPoint - 世界坐标 |
| | | * @param result - 局部坐标 |
| | | * @returns 局部坐标 |
| | | */ |
| | | worldToLocal(worldPoint: Cesium.Cartesian3, result: Cesium.Cartesian3): Cesium.Cartesian3; |
| | | } |
| | | |
| | | /** |
| | |
| | | */ |
| | | setOptions(options: any): this; |
| | | /** |
| | | * 高亮触发的事件类型,默认为单击。 |
| | | */ |
| | | eventType: EventType; |
| | | /** |
| | | * 轮廓线 宽度,单位:像素px |
| | | */ |
| | | width: number; |
| | |
| | | */ |
| | | toJSON(): any; |
| | | /** |
| | | * 获取矢量数据位置的 矩形边界值 |
| | | * @param [isFormat = true] - 是否格式化,格式化时示例: { xmin: 73.16895, xmax: 134.86816, ymin: 12.2023, ymax: 54.11485 } |
| | | * 获取数据的矩形边界 |
| | | * @param [options] - 控制参数 |
| | | * @param [options.isFormat = false] - 是否格式化,格式化时示例: { xmin: 73.16895, xmax: 134.86816, ymin: 12.2023, ymax: 54.11485 } |
| | | * @returns isFormat:true时,返回格式化对象,isFormat:false时返回Cesium.Rectangle对象 |
| | | */ |
| | | getExtent(isFormat?: boolean): Cesium.Rectangle | any; |
| | | getRectangle(options?: { |
| | | isFormat?: boolean; |
| | | }): Cesium.Rectangle | any; |
| | | /** |
| | | * 飞行定位至 数据所在的视角 |
| | | * @param [options = {}] - 参数对象: |
| | |
| | | duration?: number; |
| | | complete?: Cesium.Camera.FlightCompleteCallback; |
| | | cancel?: Cesium.Camera.FlightCancelledCallback; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | */ |
| | | getPickedObject(pickId: string): any; |
| | | /** |
| | | * 获取数据的矩形边界 |
| | | * @param [options] - 控制参数 |
| | | * @param [options.isFormat = false] - 是否格式化,格式化时示例: { xmin: 73.16895, xmax: 134.86816, ymin: 12.2023, ymax: 54.11485 } |
| | | * @returns isFormat:true时,返回格式化对象,isFormat:false时返回Cesium.Rectangle对象 |
| | | */ |
| | | getRectangle(options?: { |
| | | isFormat?: boolean; |
| | | }): Cesium.Rectangle | any; |
| | | /** |
| | | * 更新颜色 |
| | | * @param style - 样式信息 |
| | | * @param [style.color = "#3388ff"] - 颜色 |
| | |
| | | style?: ModelPrimitive.StyleOptions; |
| | | attr?: any; |
| | | }[]; |
| | | batchTable?: Cesium3DTileBatchTable; |
| | | batchTable?: Cesium.Cesium3DTileBatchTable; |
| | | requestType?: any; |
| | | gltf?: any | ArrayBuffer | Uint8Array; |
| | | basePath?: Cesium.Resource | string; |
| | |
| | | asynchronous?: boolean; |
| | | incrementallyLoadTextures?: boolean; |
| | | shadows?: Cesium.ShadowMode; |
| | | imageBasedLightingFactor?: Cartesian2; |
| | | lightColor?: Cartesian3; |
| | | imageBasedLightingFactor?: Cesium.Cartesian2; |
| | | lightColor?: Cesium.Cartesian3; |
| | | luminanceAtZenith?: number; |
| | | sphericalHarmonicCoefficients?: Cesium.Cartesian3[]; |
| | | specularEnvironmentMaps?: string; |
| | |
| | | debugWireframe?: boolean; |
| | | startTime?: Cesium.JulianDate; |
| | | delay?: number; |
| | | stopTime?: JulianDate; |
| | | stopTime?: Cesium.JulianDate; |
| | | removeOnStop?: boolean; |
| | | multiplier?: number; |
| | | reverse?: boolean; |
| | |
| | | /** |
| | | * 高亮对象。 |
| | | * @param [highlightStyle] - 高亮的样式,具体见各{@link GraphicType}矢量数据的style参数。 |
| | | * @param [closeLast = true] - 是否清除地图上上一次的高亮对象 |
| | | * @returns 无 |
| | | */ |
| | | openHighlight(highlightStyle?: any): void; |
| | | openHighlight(highlightStyle?: any, closeLast?: boolean): void; |
| | | /** |
| | | * 清除已选中的高亮 |
| | | * @returns 无 |
| | |
| | | * @property [distanceDisplayCondition_far = 10000] - 最大距离 |
| | | * @property [distanceDisplayCondition_near = 0] - 最小距离 |
| | | * @property [clampToGround = false] - 是否贴地 |
| | | * @property [heightReference = Cesium.HeightReference.NONE] - 指定高度相对于什么的属性。 |
| | | * @property [css_transform_origin = 'left bottom 0'] - DIV的 transform-origin css值 |
| | | * @property [timeRender] - 是否实时刷新全部HTML,此时需要绑定html需传入回调方法。 |
| | | * @property [setHeight] - 指定坐标高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [addHeight] - 在现有坐标基础上增加的高度值(常用于图层中配置),也支持字符串模版配置 |
| | | */ |
| | | type StyleOptions = { |
| | | html: string | Element; |
| | | html: string | Element | ((...params: any[]) => any); |
| | | horizontalOrigin?: Cesium.HorizontalOrigin; |
| | | verticalOrigin?: Cesium.VerticalOrigin; |
| | | offsetX?: number; |
| | |
| | | distanceDisplayCondition_far?: number; |
| | | distanceDisplayCondition_near?: number; |
| | | clampToGround?: boolean; |
| | | heightReference?: Cesium.HeightReference; |
| | | css_transform_origin?: string; |
| | | timeRender?: boolean; |
| | | setHeight?: number | string; |
| | | addHeight?: number | string; |
| | | }; |
| | | /** |
| | | * 当前类支持的{@link EventType}事件类型 |
| | |
| | | * @property popupClose - popup弹窗关闭 |
| | | * @property tooltipOpen - tooltip弹窗打开后 |
| | | * @property tooltipClose - tooltip弹窗关闭 |
| | | * @property highlightOpen - highlight高亮后 |
| | | * @property highlightClose - highlight关闭后 |
| | | * @property drawStart - 开始绘制 标绘事件 |
| | | * @property drawMouseMove - 正在移动鼠标中,绘制过程中鼠标移动了点 标绘事件 |
| | | * @property drawCreated - 创建完成 标绘事件 |
| | |
| | | popupClose: string; |
| | | tooltipOpen: string; |
| | | tooltipClose: string; |
| | | highlightOpen: string; |
| | | highlightClose: string; |
| | | drawStart: string; |
| | | drawMouseMove: string; |
| | | drawCreated: string; |
| | |
| | | /** |
| | | * 高亮对象。 |
| | | * @param [highlightStyle] - 高亮的样式,具体见各{@link GraphicType}矢量数据的style参数。 |
| | | * @param [closeLast = true] - 是否清除地图上上一次的高亮对象 |
| | | * @returns 无 |
| | | */ |
| | | openHighlight(highlightStyle?: any): void; |
| | | openHighlight(highlightStyle?: any, closeLast?: boolean): void; |
| | | /** |
| | | * 清除已选中的高亮 |
| | | * @returns 无 |
| | |
| | | image?: string; |
| | | emitter?: ParticleEmitter; |
| | | emissionRate?: number; |
| | | bursts?: ParticleBurst[]; |
| | | bursts?: Cesium.ParticleBurst[]; |
| | | loop?: boolean; |
| | | particleSize?: number; |
| | | imageSize?: Cartesian2; |
| | | minimumImageSize?: Cartesian2; |
| | | maximumImageSize?: Cartesian2; |
| | | imageSize?: Cesium.Cartesian2; |
| | | minimumImageSize?: Cesium.Cartesian2; |
| | | maximumImageSize?: Cesium.Cartesian2; |
| | | sizeInMeters?: boolean; |
| | | scale?: number; |
| | | startScale?: number; |
| | | endScale?: number; |
| | | color?: Color; |
| | | startColor?: Color; |
| | | endColor?: Color; |
| | | color?: Cesium.Color; |
| | | startColor?: Cesium.Color; |
| | | endColor?: Cesium.Color; |
| | | speed?: number; |
| | | minimumSpeed?: number; |
| | | maximumSpeed?: number; |
| | |
| | | mass?: number; |
| | | minimumMass?: number; |
| | | maximumMass?: number; |
| | | updateCallback?: ParticleSystem.updateCallback; |
| | | updateCallback?: Cesium.ParticleSystem.updateCallback; |
| | | }; |
| | | } |
| | | |
| | |
| | | * @property [distanceDisplayCondition_near = 0] - 最小距离 |
| | | * @property [clampToGround = false] - 是否贴地 |
| | | * @property [css_transform_origin = 'left bottom 0'] - DIV的 transform-origin css值 |
| | | * @property [timeRender] - 是否实时刷新全部HTML,此时需要绑定html需传入回调方法。 |
| | | * @property [autoCenter] - 当气泡窗口有部分在地图之外时是否自动进行居中 (目前仅俯视时准确定位) |
| | | */ |
| | | type StyleOptions = { |
| | | html: string; |
| | |
| | | distanceDisplayCondition_near?: number; |
| | | clampToGround?: boolean; |
| | | css_transform_origin?: string; |
| | | timeRender?: boolean; |
| | | autoCenter?: boolean; |
| | | }; |
| | | } |
| | | |
| | |
| | | * @property [distanceDisplayCondition_near = 0] - 最小距离 |
| | | * @property [clampToGround = false] - 是否贴地 |
| | | * @property [css_transform_origin = 'left bottom 0'] - DIV的 transform-origin css值 |
| | | * @property [timeRender] - 是否实时刷新全部HTML,此时需要绑定html需传入回调方法。 |
| | | */ |
| | | type StyleOptions = { |
| | | html: string; |
| | |
| | | distanceDisplayCondition_near?: number; |
| | | clampToGround?: boolean; |
| | | css_transform_origin?: string; |
| | | timeRender?: boolean; |
| | | }; |
| | | } |
| | | |
| | |
| | | fillColor?: Cesium.Color; |
| | | strokeColor?: Cesium.Color; |
| | | strokeWidth?: number; |
| | | backgroundColor?: vColor; |
| | | backgroundColor?: Cesium.Color; |
| | | padding?: number; |
| | | }; |
| | | }; |
| | |
| | | * @property popupClose - popup弹窗关闭 |
| | | * @property tooltipOpen - tooltip弹窗打开后 |
| | | * @property tooltipClose - tooltip弹窗关闭 |
| | | * @property highlightOpen - highlight高亮后 |
| | | * @property highlightClose - highlight关闭后 |
| | | * @property drawStart - 开始绘制 标绘事件 |
| | | * @property drawMouseMove - 正在移动鼠标中,绘制过程中鼠标移动了点 标绘事件 |
| | | * @property drawAddPoint - 绘制过程中增加了点 标绘事件 |
| | |
| | | popupClose: string; |
| | | tooltipOpen: string; |
| | | tooltipClose: string; |
| | | highlightOpen: string; |
| | | highlightClose: string; |
| | | drawStart: string; |
| | | drawMouseMove: string; |
| | | drawAddPoint: string; |
| | |
| | | /** |
| | | * 高亮对象。 |
| | | * @param [highlightStyle] - 高亮的样式,具体见各{@link GraphicType}矢量数据的style参数。 |
| | | * @param [closeLast = true] - 是否清除地图上上一次的高亮对象 |
| | | * @returns 无 |
| | | */ |
| | | openHighlight(highlightStyle?: any): void; |
| | | openHighlight(highlightStyle?: any, closeLast?: boolean): void; |
| | | /** |
| | | * 清除已选中的高亮 |
| | | * @returns 无 |
| | |
| | | * @property [translucencyByDistance] - 用于基于与相机的距离设置半透明度。 |
| | | * @property [pixelOffsetScaleByDistance] - 用于基于与相机的距离设置pixelOffset。 |
| | | * @property [imageSubRegion] - 定义用于广告牌的图像的子区域,而不是从左下角开始以像素为单位的整个图像。 |
| | | * @property [setHeight = 0] - 指定坐标高度值(常用于图层中配置) |
| | | * @property [addHeight = 0] - 在现有坐标基础上增加的高度值(常用于图层中配置) |
| | | * @property [setHeight] - 指定坐标高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [addHeight] - 在现有坐标基础上增加的高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [highlight] - 鼠标移入或单击(type:'click')后的对应高亮的部分样式,创建Graphic后也可以openHighlight、closeHighlight方法来手动调用 |
| | | * @property [label] - 支持附带文字的显示 |
| | | */ |
| | |
| | | translucencyByDistance?: Cesium.NearFarScalar; |
| | | pixelOffsetScaleByDistance?: Cesium.NearFarScalar; |
| | | imageSubRegion?: Cesium.BoundingRectangle; |
| | | setHeight?: number; |
| | | addHeight?: number; |
| | | setHeight?: number | string; |
| | | addHeight?: number | string; |
| | | highlight?: BillboardEntity.StyleOptions; |
| | | label?: LabelEntity.StyleOptions; |
| | | }; |
| | |
| | | * @property [shadows = Cesium.ShadowMode.DISABLED] - 是投射还是接收来自光源的阴影。 |
| | | * @property [clampToGround = false] - 是否贴地 |
| | | * @property [heightReference = Cesium.HeightReference.NONE] - 指定从实体位置到它的相对高度。 |
| | | * @property [setHeight = 0] - 指定坐标高度值(常用于图层中配置) |
| | | * @property [addHeight = 0] - 在现有坐标基础上增加的高度值(常用于图层中配置) |
| | | * @property [setHeight] - 指定坐标高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [addHeight] - 在现有坐标基础上增加的高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [highlight] - 鼠标移入或单击(type:'click')后的对应高亮的部分样式,创建Graphic后也可以openHighlight、closeHighlight方法来手动调用 |
| | | * @property [label] - 支持附带文字的显示 |
| | | */ |
| | |
| | | shadows?: Cesium.ShadowMode; |
| | | clampToGround?: boolean; |
| | | heightReference?: Cesium.HeightReference; |
| | | setHeight?: number; |
| | | addHeight?: number; |
| | | setHeight?: number | string; |
| | | addHeight?: number | string; |
| | | highlight?: BoxEntity.StyleOptions; |
| | | label?: LabelEntity.StyleOptions; |
| | | }; |
| | |
| | | angle: number; |
| | | } |
| | | |
| | | /** |
| | | * 定时闪烁高亮Entity(点、线、面) |
| | | */ |
| | | declare class FlickerEntity { |
| | | /** |
| | | * 高亮闪烁 Enity实体对象 |
| | | * @param entitys - entity对象或对象数组 |
| | | * @param [opts = {}] - 控制参数 |
| | | * @param [opts.time = null] - 闪烁的时长(秒),未设置时不自动停止。 |
| | | * @param [opts.color = Cesium.Color.YELLOW] - 高亮的颜色 |
| | | * @param [opts.maxAlpha = 0.3] - 闪烁的最大透明度,从 0 到 maxAlpha 渐变 |
| | | * @param [opts.onEnd = null] - 播放完成后的回调方法 |
| | | * @returns 高亮闪烁控制 对象 |
| | | */ |
| | | startFlicker(entitys: Cesium.Entity | Cesium.Entity[], opts?: { |
| | | time?: number; |
| | | color?: Cesium.Color; |
| | | maxAlpha?: number; |
| | | onEnd?: (...params: any[]) => any; |
| | | }): FlickerEntity; |
| | | /** |
| | | * 停止高亮闪烁 |
| | | * @returns 高亮闪烁控制 对象 |
| | | */ |
| | | stopFlicker(): FlickerEntity; |
| | | } |
| | | |
| | | declare namespace CorridorEntity { |
| | | /** |
| | | * 走廊 支持的样式信息 |
| | |
| | | * @property [clampToGround = false] - 是否贴地 |
| | | * @property [classificationType = Cesium.ClassificationType.BOTH] - 指定贴地时的覆盖类型,是只对地形、3dtiles 或 两者同时。 |
| | | * @property [zIndex = 0] - 层级顺序,用于排序。只有在高度和挤压高度未定义,并且走廊是静态的情况下才有效果。 |
| | | * @property [setHeight = 0] - 指定坐标高度值(常用于图层中配置) |
| | | * @property [addHeight = 0] - 在现有坐标基础上增加的高度值(常用于图层中配置) |
| | | * @property [setHeight] - 指定坐标高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [addHeight] - 在现有坐标基础上增加的高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [highlight] - 鼠标移入或单击(type:'click')后的对应高亮的部分样式,创建Graphic后也可以openHighlight、closeHighlight方法来手动调用 |
| | | * @property [label] - 支持附带文字的显示 |
| | | */ |
| | |
| | | clampToGround?: string; |
| | | classificationType?: Cesium.ClassificationType; |
| | | zIndex?: number; |
| | | setHeight?: number; |
| | | addHeight?: number; |
| | | setHeight?: number | string; |
| | | addHeight?: number | string; |
| | | highlight?: CorridorEntity.StyleOptions; |
| | | label?: LabelEntity.StyleOptions; |
| | | }; |
| | |
| | | position: Cesium.Cartesian3; |
| | | } |
| | | |
| | | /** |
| | | * Circle对象 标绘处理对应的编辑类 |
| | | */ |
| | | declare class EditCircle extends EditPoly { |
| | | } |
| | | |
| | | /** |
| | | * Corridor对象 标绘处理对应的编辑类 |
| | | */ |
| | | declare class EditCorridor extends EditPoly { |
| | | } |
| | | |
| | | /** |
| | | * Cylinder对象 标绘处理对应的编辑类 |
| | | */ |
| | | declare class EditCylinder extends EditPoly { |
| | | } |
| | | |
| | | /** |
| | | * Ellipsoid对象 标绘处理对应的编辑类 |
| | | */ |
| | | declare class EditEllipsoid extends EditBase { |
| | | } |
| | | |
| | | /** |
| | | * Model对象 标绘处理对应的编辑类 |
| | | */ |
| | | declare class EditModel extends EditBase { |
| | | } |
| | | |
| | | /** |
| | | * Plane对象 标绘处理对应的编辑类 |
| | | */ |
| | | declare class EditPlane extends EditBase { |
| | | } |
| | | |
| | | /** |
| | | * Point 对象 标绘处理对应的编辑类 |
| | | */ |
| | | declare class EditPoint extends EditBase { |
| | | } |
| | | |
| | | /** |
| | | * 线面状对象 标绘处理对应的编辑类基类 |
| | | */ |
| | | declare class EditPoly extends EditBase { |
| | | } |
| | | |
| | | /** |
| | | * Polygon对象 标绘处理对应的编辑类 |
| | | */ |
| | | declare class EditPolygon extends EditPoly { |
| | | } |
| | | |
| | | /** |
| | | * Polygon对象 标绘处理对应的编辑类, |
| | | * 用于外部扩展使用,绘制的点与显示的点不一致的标号 |
| | | */ |
| | | declare class EditPolygonEx extends EditPolygon { |
| | | } |
| | | |
| | | /** |
| | | * Rectangle对象 标绘处理对应的编辑类, |
| | | */ |
| | | declare class EditRectangle extends EditPoly { |
| | | } |
| | | |
| | | /** |
| | | * Wall对象 标绘处理对应的编辑类, |
| | | */ |
| | | declare class EditWall extends EditPoly { |
| | | } |
| | | |
| | | declare namespace FontBillboardEntity { |
| | | /** |
| | | * Font CSS字体点转图片后的图标点 Entity 支持的样式信息 |
| | |
| | | * @property [visibleDepth = true] - 是否被遮挡 |
| | | * @property [disableDepthTestDistance] - 指定从相机到禁用深度测试的距离。 |
| | | * @property [translucencyByDistance] - 用于基于与相机的距离设置半透明度。 |
| | | * @property [setHeight = 0] - 指定坐标高度值(常用于图层中配置) |
| | | * @property [addHeight = 0] - 在现有坐标基础上增加的高度值(常用于图层中配置) |
| | | * @property [setHeight] - 指定坐标高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [addHeight] - 在现有坐标基础上增加的高度值(常用于图层中配置),也支持字符串模版配置 |
| | | */ |
| | | type StyleOptions = { |
| | | text?: string; |
| | |
| | | visibleDepth?: boolean; |
| | | disableDepthTestDistance?: number; |
| | | translucencyByDistance?: Cesium.NearFarScalar; |
| | | setHeight?: number; |
| | | addHeight?: number; |
| | | setHeight?: number | string; |
| | | addHeight?: number | string; |
| | | }; |
| | | } |
| | | |
| | |
| | | * @property [distanceDisplayCondition = false] - 是否按视距显示 或 指定此框将显示在与摄像机的多大距离。 |
| | | * @property [distanceDisplayCondition_far = 100000] - 最大距离 |
| | | * @property [distanceDisplayCondition_near = 0] - 最小距离 |
| | | * @property [setHeight = 0] - 指定坐标高度值(常用于图层中配置) |
| | | * @property [addHeight = 0] - 在现有坐标基础上增加的高度值(常用于图层中配置) |
| | | * @property [setHeight] - 指定坐标高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [addHeight] - 在现有坐标基础上增加的高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [label] - 支持附带文字的显示 |
| | | */ |
| | | type StyleOptions = { |
| | |
| | | distanceDisplayCondition?: boolean | Cesium.DistanceDisplayCondition; |
| | | distanceDisplayCondition_far?: number; |
| | | distanceDisplayCondition_near?: number; |
| | | setHeight?: number; |
| | | addHeight?: number; |
| | | setHeight?: number | string; |
| | | addHeight?: number | string; |
| | | label?: LabelEntity.StyleOptions; |
| | | }; |
| | | } |
| | |
| | | pitch: number; |
| | | roll: number; |
| | | duration?: number; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | * @property [distanceDisplayCondition_near = 0] - 最小距离 |
| | | * @property [hasShadows = false] - 是否阴影 |
| | | * @property [shadows = Cesium.ShadowMode.DISABLED] - 指定平面是投射还是接收来自光源的阴影。 |
| | | * @property [setHeight = 0] - 指定坐标高度值(常用于图层中配置) |
| | | * @property [addHeight = 0] - 在现有坐标基础上增加的高度值(常用于图层中配置) |
| | | * @property [setHeight] - 指定坐标高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [addHeight] - 在现有坐标基础上增加的高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [highlight] - 鼠标移入或单击(type:'click')后的对应高亮的部分样式,创建Graphic后也可以openHighlight、closeHighlight方法来手动调用 |
| | | * @property [label] - 支持附带文字的显示 |
| | | */ |
| | |
| | | distanceDisplayCondition_near?: number; |
| | | hasShadows?: boolean; |
| | | shadows?: Cesium.ShadowMode; |
| | | setHeight?: number; |
| | | addHeight?: number; |
| | | setHeight?: number | string; |
| | | addHeight?: number | string; |
| | | highlight?: PlaneEntity.StyleOptions; |
| | | label?: LabelEntity.StyleOptions; |
| | | }; |
| | |
| | | * @property [translucencyByDistance] - 用于基于与相机的距离设置半透明度。 |
| | | * @property [clampToGround = false] - 是否贴地 |
| | | * @property [heightReference = Cesium.HeightReference.NONE] - 指定高度相对于什么的属性。 |
| | | * @property [setHeight = 0] - 指定坐标高度值(常用于图层中配置) |
| | | * @property [addHeight = 0] - 在现有坐标基础上增加的高度值(常用于图层中配置) |
| | | * @property [setHeight] - 指定坐标高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [addHeight] - 在现有坐标基础上增加的高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [highlight] - 鼠标移入或单击(type:'click')后的对应高亮的部分样式,创建Graphic后也可以openHighlight、closeHighlight方法来手动调用 |
| | | * @property [label] - 支持附带文字的显示 |
| | | */ |
| | |
| | | translucencyByDistance?: Cesium.NearFarScalar; |
| | | clampToGround?: boolean; |
| | | heightReference?: Cesium.HeightReference; |
| | | setHeight?: number; |
| | | addHeight?: number; |
| | | setHeight?: number | string; |
| | | addHeight?: number | string; |
| | | highlight?: PointEntity.StyleOptions; |
| | | label?: LabelEntity.StyleOptions; |
| | | }; |
| | |
| | | * @property [clampToGround = false] - 是否贴地 |
| | | * @property [classificationType = Cesium.ClassificationType.BOTH] - 指定贴地时的覆盖类型,是只对地形、3dtiles 或 两者同时。 |
| | | * @property [zIndex = 0] - 层级顺序,指定用于排序地面几何的zIndex。只有当矩形为常量且没有指定height或extrdedheight时才有效果。 |
| | | * @property [setHeight = 0] - 指定坐标高度值(常用于图层中配置) |
| | | * @property [addHeight = 0] - 在现有坐标基础上增加的高度值(常用于图层中配置) |
| | | * @property [setHeight] - 指定坐标高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [addHeight] - 在现有坐标基础上增加的高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [highlight] - 鼠标移入或单击(type:'click')后的对应高亮的部分样式,创建Graphic后也可以openHighlight、closeHighlight方法来手动调用 |
| | | * @property [label] - 支持附带文字的显示 |
| | | */ |
| | |
| | | clampToGround?: string; |
| | | classificationType?: Cesium.ClassificationType; |
| | | zIndex?: number; |
| | | setHeight?: number; |
| | | addHeight?: number; |
| | | setHeight?: number | string; |
| | | addHeight?: number | string; |
| | | highlight?: RectangleEntity.StyleOptions; |
| | | label?: LabelEntity.StyleOptions; |
| | | }; |
| | |
| | | */ |
| | | getOutlineCoordinates(closure?: boolean, noAlt: boolean): any[][]; |
| | | /** |
| | | * 获取数据的矩形边界 |
| | | * @param [options] - 控制参数 |
| | | * @param [options.isFormat = false] - 是否格式化,格式化时示例: { xmin: 73.16895, xmax: 134.86816, ymin: 12.2023, ymax: 54.11485 } |
| | | * @returns isFormat:true时,返回格式化对象,isFormat:false时返回Cesium.Rectangle对象 |
| | | */ |
| | | getRectangle(options?: { |
| | | isFormat?: boolean; |
| | | }): Cesium.Rectangle | any; |
| | | /** |
| | | * 判断点是否在矩形内 |
| | | * @param position - 需要判断的点 |
| | | * @returns 是否在矩形内 |
| | |
| | | duration?: number; |
| | | complete?: Cesium.Camera.FlightCompleteCallback; |
| | | cancel?: Cesium.Camera.FlightCancelledCallback; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | * @property [hasShadows = false] - 是否阴影 |
| | | * @property [shadows = Cesium.ShadowMode.DISABLED] - 指定墙壁是投射还是接收来自光源的阴影。 |
| | | * @property [granularity = Cesium.Math.RADIANS_PER_DEGREE] - 指定每个纬度点和经度点之间的角距离。 |
| | | * @property [setHeight = 0] - 指定坐标高度值(常用于图层中配置) |
| | | * @property [addHeight = 0] - 在现有坐标基础上增加的高度值(常用于图层中配置) |
| | | * @property [setHeight] - 指定坐标高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [addHeight] - 在现有坐标基础上增加的高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [highlight] - 鼠标移入或单击(type:'click')后的对应高亮的部分样式,创建Graphic后也可以openHighlight、closeHighlight方法来手动调用 |
| | | * @property [label] - 支持附带文字的显示,额外支持: |
| | | * @property [label.position] - 文字所在位置,默认是矢量对象本身的center属性值。支持配置 'center':围合面的内部中心点坐标,'{xxxx}'配置属性字段, 或者直接指定坐标值。 |
| | |
| | | hasShadows?: boolean; |
| | | shadows?: Cesium.ShadowMode; |
| | | granularity?: number; |
| | | setHeight?: number; |
| | | addHeight?: number; |
| | | setHeight?: number | string; |
| | | addHeight?: number | string; |
| | | highlight?: WallEntity.StyleOptions; |
| | | label?: { |
| | | position?: string | LatLngPoint; |
| | |
| | | type ConstructorOptions = { |
| | | appearance?: Cesium.Appearance; |
| | | attributes?: Cesium.Appearance; |
| | | depthFailAppearance?: Appearance; |
| | | depthFailAppearance?: Cesium.Appearance; |
| | | vertexCacheOptimize?: boolean; |
| | | interleave?: boolean; |
| | | compressVertices?: boolean; |
| | |
| | | * @property popupClose - popup弹窗关闭 |
| | | * @property tooltipOpen - tooltip弹窗打开后 |
| | | * @property tooltipClose - tooltip弹窗关闭 |
| | | * @property highlightOpen - highlight高亮后 |
| | | * @property highlightClose - highlight关闭后 |
| | | */ |
| | | type EventType = { |
| | | 通用: BaseGraphic.EventType; |
| | |
| | | popupClose: string; |
| | | tooltipOpen: string; |
| | | tooltipClose: string; |
| | | highlightOpen: string; |
| | | highlightClose: string; |
| | | }; |
| | | } |
| | | |
| | |
| | | */ |
| | | readonly geometryInstanceAttributes: any; |
| | | /** |
| | | * 对应材质的uniforms |
| | | * 对应材质的uniforms(当赋有材质时), |
| | | * 一个对象,它的属性被用来设置片段着色器shader。 |
| | | * <p> |
| | | * 对象属性值可以是常量或函数。这个函数将在每一帧后处理阶段执行之前被调用。 |
| | |
| | | /** |
| | | * 高亮对象。 |
| | | * @param [highlightStyle] - 高亮的样式,具体见各{@link GraphicType}矢量数据的style参数。 |
| | | * @param [closeLast = true] - 是否清除地图上上一次的高亮对象 |
| | | * @returns 无 |
| | | */ |
| | | openHighlight(highlightStyle?: any): void; |
| | | openHighlight(highlightStyle?: any, closeLast?: boolean): void; |
| | | /** |
| | | * 清除已选中的高亮 |
| | | * @returns 无 |
| | |
| | | * @property [vertexShaderSource] - 可选的GLSL顶点着色器源,覆盖默认的顶点着色器。 |
| | | * @property [fragmentShaderSource] - 可选的GLSL片段着色器源覆盖默认的片段着色器。 |
| | | * @property [renderState] - 可选渲染状态,以覆盖默认渲染状态。 |
| | | * @property [setHeight = 0] - 指定坐标高度值(常用于图层中配置) |
| | | * @property [addHeight = 0] - 在现有坐标基础上增加的高度值(常用于图层中配置) |
| | | * @property [setHeight] - 指定坐标高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [addHeight] - 在现有坐标基础上增加的高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [highlight] - 鼠标移入或单击(type:'click')后的对应高亮的部分样式,创建Graphic后也可以openHighlight、closeHighlight方法来手动调用 |
| | | * @property [label] - 支持附带文字的显示 |
| | | */ |
| | |
| | | roll?: number; |
| | | materialType?: string; |
| | | material材质参数?: any; |
| | | material?: Material; |
| | | material?: Cesium.Material; |
| | | color?: string | Cesium.Color; |
| | | opacity?: number; |
| | | outline?: boolean; |
| | | outlineColor?: string | Cesium.Color; |
| | | outlineOpacity?: number; |
| | | materialSupport?: MaterialAppearance.MaterialSupportType; |
| | | materialSupport?: Cesium.MaterialAppearance.MaterialSupportType; |
| | | flat?: boolean; |
| | | faceForward?: boolean; |
| | | translucent?: boolean; |
| | |
| | | vertexShaderSource?: string; |
| | | fragmentShaderSource?: string; |
| | | renderState?: any; |
| | | setHeight?: number; |
| | | addHeight?: number; |
| | | setHeight?: number | string; |
| | | addHeight?: number | string; |
| | | highlight?: BoxPrimitive.StyleOptions; |
| | | label?: LabelEntity.StyleOptions; |
| | | }; |
| | |
| | | * @property [vertexShaderSource] - 可选的GLSL顶点着色器源,覆盖默认的顶点着色器。 |
| | | * @property [fragmentShaderSource] - 可选的GLSL片段着色器源覆盖默认的片段着色器。 |
| | | * @property [renderState] - 可选渲染状态,以覆盖默认渲染状态。 |
| | | * @property [setHeight = 0] - 指定坐标高度值(常用于图层中配置) |
| | | * @property [addHeight = 0] - 在现有坐标基础上增加的高度值(常用于图层中配置) |
| | | * @property [setHeight] - 指定坐标高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [addHeight] - 在现有坐标基础上增加的高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [highlight] - 鼠标移入或单击(type:'click')后的对应高亮的部分样式,创建Graphic后也可以openHighlight、closeHighlight方法来手动调用 |
| | | * @property [label] - 支持附带文字的显示 |
| | | */ |
| | |
| | | granularity?: number; |
| | | materialType?: string; |
| | | material材质参数?: any; |
| | | material?: Material; |
| | | material?: Cesium.Material; |
| | | color?: string | Cesium.Color; |
| | | opacity?: number; |
| | | outline?: boolean; |
| | |
| | | vertexShaderSource?: string; |
| | | fragmentShaderSource?: string; |
| | | renderState?: any; |
| | | setHeight?: number; |
| | | addHeight?: number; |
| | | setHeight?: number | string; |
| | | addHeight?: number | string; |
| | | highlight?: CirclePrimitive.StyleOptions; |
| | | label?: LabelEntity.StyleOptions; |
| | | }; |
| | |
| | | * 圆的半径(单位:米) |
| | | */ |
| | | radius: number; |
| | | /** |
| | | * 圆的边线坐标集合(笛卡尔坐标) |
| | | */ |
| | | readonly outlinePositions: Cesium.Cartesian3[]; |
| | | /** |
| | | * 获取圆的边线坐标集合(笛卡尔坐标) |
| | | * @param [closure = true] - 是否闭合,true时会添加第0个点进行闭合。 |
| | | * @param [count = 90] - 象限内点的数量,返回的总数为 count*4 |
| | | * @returns 边线坐标数组 |
| | | */ |
| | | getOutlinePositions(closure?: boolean, count?: number): Cesium.Cartesian3[]; |
| | | /** |
| | | * 获取数据的矩形边界 |
| | | * @param [options] - 控制参数 |
| | | * @param [options.isFormat = false] - 是否格式化,格式化时示例: { xmin: 73.16895, xmax: 134.86816, ymin: 12.2023, ymax: 54.11485 } |
| | | * @returns isFormat:true时,返回格式化对象,isFormat:false时返回Cesium.Rectangle对象 |
| | | */ |
| | | getRectangle(options?: { |
| | | isFormat?: boolean; |
| | | }): Cesium.Rectangle | any; |
| | | /** |
| | | * 判断点是否在圆内 |
| | | * @param position - 需要判断的点 |
| | |
| | | duration?: number; |
| | | complete?: Cesium.Camera.FlightCompleteCallback; |
| | | cancel?: Cesium.Camera.FlightCancelledCallback; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | * @property [vertexShaderSource] - 可选的GLSL顶点着色器源,覆盖默认的顶点着色器。 |
| | | * @property [fragmentShaderSource] - 可选的GLSL片段着色器源覆盖默认的片段着色器。 |
| | | * @property [renderState] - 可选渲染状态,以覆盖默认渲染状态。 |
| | | * @property [setHeight = 0] - 指定坐标高度值(常用于图层中配置) |
| | | * @property [addHeight = 0] - 在现有坐标基础上增加的高度值(常用于图层中配置) |
| | | * @property [setHeight] - 指定坐标高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [addHeight] - 在现有坐标基础上增加的高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [label] - 支持附带文字的显示 |
| | | */ |
| | | type StyleOptions = { |
| | |
| | | cornerType?: string | Cesium.CornerType; |
| | | materialType?: string; |
| | | material材质参数?: any; |
| | | material?: Material; |
| | | material?: Cesium.Material; |
| | | color?: string | Cesium.Color; |
| | | opacity?: number; |
| | | outline?: boolean; |
| | |
| | | vertexShaderSource?: string; |
| | | fragmentShaderSource?: string; |
| | | renderState?: any; |
| | | setHeight?: number; |
| | | addHeight?: number; |
| | | setHeight?: number | string; |
| | | addHeight?: number | string; |
| | | label?: LabelPrimitive.StyleOptions; |
| | | }; |
| | | } |
| | |
| | | roll?: number; |
| | | materialType?: string; |
| | | material材质参数?: any; |
| | | material?: Material; |
| | | material?: Cesium.Material; |
| | | color?: string | Cesium.Color; |
| | | opacity?: number; |
| | | outline?: boolean; |
| | | outlineColor?: string | Cesium.Color; |
| | | outlineOpacity?: number; |
| | | materialSupport?: MaterialAppearance.MaterialSupportType; |
| | | materialSupport?: Cesium.MaterialAppearance.MaterialSupportType; |
| | | flat?: boolean; |
| | | faceForward?: boolean; |
| | | translucent?: boolean; |
| | |
| | | * @property [multiplier = 1.0] - 大于1.0的值增加动画播放的速度相对于场景时钟的速度;小于1.0会降低速度。 |
| | | * @property [reverse = false] - 当true时,动画会反向播放。 |
| | | * @property [loop = Cesium.ModelAnimationLoop.REPEAT] - 决定动画是否循环以及如何循环。 |
| | | * @property [setHeight = 0] - 指定坐标高度值(常用于图层中配置) |
| | | * @property [addHeight = 0] - 在现有坐标基础上增加的高度值(常用于图层中配置) |
| | | * @property [setHeight] - 指定坐标高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [addHeight] - 在现有坐标基础上增加的高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [highlight] - 鼠标移入或单击(type:'click')后的对应高亮的部分样式,创建Graphic后也可以openHighlight、closeHighlight方法来手动调用 |
| | | * @property [label] - 支持附带文字的显示 |
| | | */ |
| | |
| | | runAnimations?: boolean; |
| | | clampAnimations?: boolean; |
| | | imageBasedLightingFactor?: Cesium.Cartesian2; |
| | | lightColor?: Color; |
| | | lightColor?: Cesium.Color; |
| | | nodeTransformations?: Cesium.PropertyBag | { |
| | | [key: string]: Cesium.TranslationRotationScale; |
| | | }; |
| | |
| | | debugWireframe?: boolean; |
| | | startTime?: Cesium.JulianDate; |
| | | delay?: number; |
| | | stopTime?: JulianDate; |
| | | stopTime?: Cesium.JulianDate; |
| | | removeOnStop?: boolean; |
| | | multiplier?: number; |
| | | reverse?: boolean; |
| | | loop?: Cesium.ModelAnimationLoop; |
| | | setHeight?: number; |
| | | addHeight?: number; |
| | | setHeight?: number | string; |
| | | addHeight?: number | string; |
| | | highlight?: ModelPrimitive.StyleOptions; |
| | | label?: LabelEntity.StyleOptions; |
| | | }; |
| | |
| | | opacity?: number; |
| | | materialType?: string; |
| | | material材质参数?: any; |
| | | material?: Material; |
| | | materialSupport?: MaterialAppearance.MaterialSupportType; |
| | | material?: Cesium.Material; |
| | | materialSupport?: Cesium.MaterialAppearance.MaterialSupportType; |
| | | outline?: boolean; |
| | | outlineColor?: string | Cesium.Color; |
| | | outlineOpacity?: number; |
| | |
| | | * @property [visibleDepth = true] - 是否被遮挡 |
| | | * @property [disableDepthTestDistance] - 指定从相机到禁用深度测试的距离。 |
| | | * @property [translucencyByDistance] - 用于基于与相机的距离设置半透明度。 |
| | | * @property [setHeight = 0] - 指定坐标高度值(常用于图层中配置) |
| | | * @property [addHeight = 0] - 在现有坐标基础上增加的高度值(常用于图层中配置) |
| | | * @property [setHeight] - 指定坐标高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [addHeight] - 在现有坐标基础上增加的高度值(常用于图层中配置),也支持字符串模版配置 |
| | | * @property [label] - 支持附带文字的显示 |
| | | */ |
| | | type StyleOptions = { |
| | |
| | | visibleDepth?: boolean; |
| | | disableDepthTestDistance?: number; |
| | | translucencyByDistance?: Cesium.NearFarScalar; |
| | | setHeight?: number; |
| | | addHeight?: number; |
| | | setHeight?: number | string; |
| | | addHeight?: number | string; |
| | | label?: LabelPrimitive.StyleOptions; |
| | | }; |
| | | } |
| | |
| | | type StyleOptions = { |
| | | materialType?: string; |
| | | material材质参数?: any; |
| | | material?: Material; |
| | | material?: Cesium.Material; |
| | | color?: string | Cesium.Color; |
| | | opacity?: number; |
| | | randomColor?: boolean; |
| | |
| | | width?: number; |
| | | materialType?: string; |
| | | material材质参数?: any; |
| | | material?: Material; |
| | | material?: Cesium.Material; |
| | | color?: string | Cesium.Color; |
| | | opacity?: number; |
| | | randomColor?: boolean; |
| | |
| | | diffHeight?: number; |
| | | materialType?: string; |
| | | material材质参数?: any; |
| | | material?: Material; |
| | | material?: Cesium.Material; |
| | | color?: string | Cesium.Color; |
| | | opacity?: number; |
| | | outline?: boolean; |
| | |
| | | */ |
| | | readonly position: Cesium.Cartesian3; |
| | | /** |
| | | * 当前飞行过的positions轨迹点数组的index顺序 |
| | | */ |
| | | readonly currIndex: number; |
| | | /** |
| | | * 贴模型分析时,排除的不进行贴模型计算的模型对象,默认是当前本身,可以是: primitives, entities 等 |
| | | */ |
| | | readonly objectsToExclude: object[] | undefined; |
| | |
| | | * 中心点坐标(笛卡尔坐标),popup/tooltip等功能会使用 |
| | | */ |
| | | readonly center: Cesium.SampledPositionProperty; |
| | | /** |
| | | * 已经飞行过的点的 index |
| | | */ |
| | | readonly indexForFlyOK: Int; |
| | | /** |
| | | * 获取三维空间中的旋转。 |
| | | */ |
| | |
| | | readonly hpr: Cesium.HeadingPitchRoll; |
| | | /** |
| | | * 获取当前转换计算模型矩阵。如果方向或位置未定义,则返回undefined。 |
| | | */ |
| | | readonly modelMatrix: Cesium.Matrix4; |
| | | /** |
| | | * 获取当前转换计算模型矩阵。如果方向或位置未定义,则返回undefined。 |
| | | * 同 modelMatrix |
| | | */ |
| | | readonly matrix: Cesium.Matrix4; |
| | | /** |
| | |
| | | followedZ?: followedZ; |
| | | }): void; |
| | | /** |
| | | * 获取飞过的路线坐标数组 |
| | | * @returns 坐标数组 |
| | | */ |
| | | getOverPositions(): Cesium.Cartesian3[]; |
| | | /** |
| | | * 按类型 添加单个投影 |
| | | * @param item - 参数,按类型分别支持: |
| | | * @param [item.wall] - wall类型所支持的参数 |
| | |
| | | duration?: number; |
| | | complete?: Cesium.Camera.FlightCompleteCallback; |
| | | cancel?: Cesium.Camera.FlightCancelledCallback; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | pitch: number; |
| | | roll: number; |
| | | duration?: number; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | * @param [options.camera.offsetX = 0] - 'dy'锁定第一视角时,锁定点的本身的X轴方向(前后)偏移值 |
| | | * @param [options.camera.offsetY = 0] - 'dy'锁定第一视角时,锁定点的本身的Y轴方向(横向)偏移值 |
| | | * @param [options.camera.offsetZ = 0] - 'dy'锁定第一视角时,锁定点的本身的Z轴方向(高度)偏移值 |
| | | * @param [forwardExtrapolationType = Cesium.ExtrapolationType.HOLD] - 在任何可用坐标之后一次请求值时要执行的推断类型,默认为最后一个坐标位置。 |
| | | * @param [backwardExtrapolationType = Cesium.ExtrapolationType.HOLD] - 在任何可用坐标之前一次请求值时要执行的推断类型,默认为第一个坐标位置。 |
| | | * @param [options.clampToTileset = false] - 是否贴3dtiles模型上(贴模型效率较慢,按需开启) |
| | | * @param [options.frameRate = 30] - 当clampToTileset:true时,控制贴模型的效率,多少帧计算一次贴模型高度, |
| | | * @param [options.objectsToExclude = null] - 贴模型分析时,排除的不进行贴模型计算的模型对象,默认是当前本身,可以是: primitives, entities, 或 3D Tiles features |
| | |
| | | clampToTileset?: boolean; |
| | | frameRate?: number; |
| | | objectsToExclude?: object[]; |
| | | }); |
| | | }, forwardExtrapolationType?: Cesium.ExtrapolationType, backwardExtrapolationType?: Cesium.ExtrapolationType); |
| | | /** |
| | | * 将轨迹数据转换为CZML格式数据 |
| | | * @example |
| | |
| | | * @param [options.fixedFrameTransform = Cesium.Transforms.eastNorthUpToFixedFrame] - 参考系 |
| | | * @param [options.interpolation = false] - 是否LagrangePolynomialApproximation插值,对轨迹进行圆弧状插值 |
| | | * @param [options.interpolationDegree = 2] - 当interpolation为true时,使用的插值程度。 |
| | | * @param [options.showStop = false] - 是否在start前或stop后显示模型等对象 |
| | | * @param [options.label] - 设置是否显示 文本 和对应的样式 |
| | | * @param [options.showGroundHeight = false] - 是否求准确的 地面海拔 和 离地高度 (没有此需求时可以关闭,提高效率) |
| | | * @param [options.model] - 设置是否显示 gltf模型 和对应的样式 |
| | |
| | | * @param [options.camera.offsetZ = 0] - 'dy'锁定第一视角时,锁定点的本身的Z轴方向(高度)偏移值 |
| | | * @param [options.clockRange] - 指定播放的模式 |
| | | * @param [options.clockLoop = false] - 是否循环播放,等价于clockRange:Cesium.ClockRange.LOOP_STOP |
| | | * @param [forwardExtrapolationType = Cesium.ExtrapolationType.HOLD] - 在任何可用坐标之后一次请求值时要执行的推断类型,默认为最后一个坐标位置。 |
| | | * @param [backwardExtrapolationType = Cesium.ExtrapolationType.HOLD] - 在任何可用坐标之前一次请求值时要执行的推断类型,默认为第一个坐标位置。 |
| | | * @param [options.showStop = false] - 是否在start前或stop后显示模型等对象 |
| | | * @param [options.autoStop = false] - 是否自动停止 |
| | | * |
| | | * //以下是 clampToGround中使用的 |
| | |
| | | fixedFrameTransform?: Cesium.Transforms.LocalFrameToFixedFrame; |
| | | interpolation?: boolean; |
| | | interpolationDegree?: boolean; |
| | | showStop?: boolean; |
| | | label?: LabelEntity.StyleOptions; |
| | | showGroundHeight?: boolean; |
| | | model?: ModelEntity.StyleOptions; |
| | |
| | | }; |
| | | clockRange?: Cesium.ClockRange; |
| | | clockLoop?: boolean; |
| | | showStop?: boolean; |
| | | autoStop?: boolean; |
| | | splitNum?: number; |
| | | minDistance?: number; |
| | |
| | | clampToTileset?: boolean; |
| | | frameRate?: number; |
| | | objectsToExclude?: object[]; |
| | | }); |
| | | /** |
| | | * 当前飞行过的positions轨迹点数组的index顺序 |
| | | */ |
| | | readonly currIndex: number; |
| | | }, forwardExtrapolationType?: Cesium.ExtrapolationType, backwardExtrapolationType?: Cesium.ExtrapolationType); |
| | | /** |
| | | * 是否已启动 |
| | | */ |
| | |
| | | duration?: number; |
| | | complete?: Cesium.Camera.FlightCompleteCallback; |
| | | cancel?: Cesium.Camera.FlightCancelledCallback; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | duration?: number; |
| | | complete?: Cesium.Camera.FlightCompleteCallback; |
| | | cancel?: Cesium.Camera.FlightCancelledCallback; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | * 加载展示 GeoJSON数据 的图层 |
| | | * @param options - 参数对象,包括以下: |
| | | * @param [options.通用参数] - 包含父类支持的所有参数 |
| | | * @param [options.url] - SDK标绘生产的geojson文件或服务url地址 |
| | | * @param [options.data] - SDK标绘生产的geojson格式规范数据对象,与url二选一即可。 |
| | | * @param [options.url] - geojson文件或服务url地址 |
| | | * @param [options.data] - geojson格式规范数据对象,与url二选一即可。 |
| | | * @param [options.crs] - 原始数据的坐标系,如'EPSG:3857' |
| | | * @param [options.format] - 可以对加载的geojson数据进行格式化或转换操作 |
| | | * @param [options.onCreateGraphic] - 解析geojson后,外部自定义方法来创建Graphic对象 |
| | |
| | | * @param [options.templateValues] - 一个对象,用于替换Url中的模板值的键/值对 |
| | | * @param [options.queryParameters] - 一个对象,其中包含在检索资源时将发送的查询参数。比如:queryParameters: {'access_token': '123-435-456-000'} |
| | | * @param [options.headers] - 一个对象,将发送的其他HTTP标头。比如:headers: { 'X-My-Header': 'valueOfHeader' } |
| | | * @param [options.graphicOptions] - 默认的graphic的构造参数,每种不同类型数据都有不同的属性,具体见各{@link GraphicType}矢量数据的构造参数。 |
| | | * @param [options.symbol] - 矢量数据的style样式,为Function时是完全自定义的回调处理 symbol(attr, style, feature) |
| | | * @param [options.symbol.type] - 标识数据类型,默认是根据数据生成 point、polyline、polygon |
| | | * @param options.symbol.styleOptions - Style样式,每种不同类型数据都有不同的样式,具体见各{@link GraphicType}矢量数据的style参数。 |
| | |
| | | templateValues?: any; |
| | | queryParameters?: any; |
| | | headers?: any; |
| | | graphicOptions?: any; |
| | | symbol?: { |
| | | type?: GraphicType; |
| | | styleOptions: any; |
| | |
| | | style?: any; |
| | | layer?: string; |
| | | }): BaseGraphic[]; |
| | | /** |
| | | * 获取图层内所有数据的 矩形边界值 |
| | | * @param [isFormat = false] - 是否格式化,格式化时示例: { xmin: 73.16895, xmax: 134.86816, ymin: 12.2023, ymax: 54.11485 } |
| | | * @returns isFormat:true时,返回格式化对象,isFormat:false时返回Cesium.Rectangle对象 |
| | | */ |
| | | getRectangle(isFormat?: boolean): Cesium.Rectangle | any; |
| | | /** |
| | | * 开始绘制矢量数据,绘制的数据会加载在当前图层。 |
| | | * @param options - Graphic构造参数,包含: |
| | |
| | | */ |
| | | _removedHook(): void; |
| | | /** |
| | | * 获取图层内所有数据的 矩形边界值 |
| | | * @param [isFormat = false] - 是否格式化,格式化时示例: { xmin: 73.16895, xmax: 134.86816, ymin: 12.2023, ymax: 54.11485 } |
| | | * @returns isFormat:true时,返回格式化对象,isFormat:false时返回Cesium.Rectangle对象 |
| | | */ |
| | | getRectangle(isFormat?: boolean): Cesium.Rectangle | any; |
| | | /** |
| | | * 将图层数据导出为GeoJSON格式规范对象。 |
| | | * @param [options] - 参数对象: |
| | | * @param [options.noAlt] - 不导出高度值 |
| | |
| | | * @param [options] - 加载控制参数,包含: |
| | | * @param [options.clear = false] - 是否清除图层已有数据 |
| | | * @param [options.flyTo = false] - 是否加载完成后进行飞行到数据区域 |
| | | * @param [options.style] - 可以设置指定style样式 |
| | | * @param [options.type] - 转为指定的类型 |
| | | * @param [options.style] - 可以设置指定style样式,每种不同类型数据都有不同的样式,具体见各矢量数据的style参数。{@link GraphicType} |
| | | * @param [options.crs] - 原始数据的坐标系,如'EPSG:3857' (可以从 {@link http://epsg.io }查询) |
| | | * @returns 转换后的Graphic对象数组 |
| | | */ |
| | | loadGeoJSON(geojson: string | any, options?: { |
| | | clear?: boolean; |
| | | flyTo?: boolean; |
| | | type?: GraphicType; |
| | | style?: any; |
| | | crs?: string; |
| | | }): BaseGraphic[]; |
| | | /** |
| | | * 添加Graphic矢量数据 |
| | |
| | | duration?: number; |
| | | complete?: Cesium.Camera.FlightCompleteCallback; |
| | | cancel?: Cesium.Camera.FlightCancelledCallback; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | * @property allTilesLoaded - 3dtiles模型 |
| | | * @property loadBefore - 完成加载,但未做任何其他处理前 |
| | | * @property load - 完成加载,执行所有内部处理后 |
| | | * @property highlightOpen - highlight高亮后 |
| | | * @property highlightClose - highlight关闭后 |
| | | */ |
| | | type EventType = { |
| | | 通用: BaseGraphicLayer.EventType; |
| | |
| | | allTilesLoaded: string; |
| | | loadBefore: string; |
| | | load: string; |
| | | highlightOpen: string; |
| | | highlightClose: string; |
| | | }; |
| | | } |
| | | |
| | |
| | | * @param [options.marsJzwStyle = false] - 开启或设置建筑物特效样式。 |
| | | * @param [options.highlight] - 高亮及其样式配置 |
| | | * @param [options.highlight.type] - 鼠标移入高亮 或 单击高亮(type:'click') |
| | | * @param [options.highlight.all] - 是否整体高亮, true:模型整体全部高亮,false:单个构件高亮 |
| | | * @param [options.highlight.color = '#FFFF00'] - 颜色,支持rgba字符串 |
| | | * @param [options.highlight.opacity = 1.0] - 透明度 |
| | | * @param [options.highlight.outlineEffect = false] - 默认为修改矢量对象本身的style高亮,true时采用{@link OutlineEffect}方式高亮。 |
| | | * @param [options.highlight.其他] - outlineEffect:true时对应的参数信息 |
| | | * @param [options.clampToGround] - 是否贴地,true时自动调用贴地计算,但此属性只适合标准的与地形数据匹配的模型,并不精确,建议通过模型编辑页面调试给具体高度值。 |
| | |
| | | clippingPlanes?: ClippingPlaneCollection; |
| | | classificationType?: ClassificationType; |
| | | pointCloudShading?: any; |
| | | imageBasedLightingFactor?: Cartesian2; |
| | | lightColor?: Cartesian3; |
| | | imageBasedLightingFactor?: Cesium.Cartesian2; |
| | | lightColor?: Cesium.Cartesian3; |
| | | luminanceAtZenith?: number; |
| | | sphericalHarmonicCoefficients?: Cartesian3[]; |
| | | specularEnvironmentMaps?: string; |
| | |
| | | marsJzwStyle?: boolean | string; |
| | | highlight?: { |
| | | type?: string; |
| | | all?: boolean; |
| | | color?: string; |
| | | opacity?: number; |
| | | outlineEffect?: boolean; |
| | | 其他?: OutlineEffect.Options; |
| | | }; |
| | |
| | | /** |
| | | * 高亮对象。 |
| | | * @param [highlightStyle] - 高亮的样式,具体见各{@link GraphicType}矢量数据的style参数。 |
| | | * @param [closeLast = true] - 是否清除地图上上一次的高亮对象 |
| | | * @returns 无 |
| | | */ |
| | | openHighlight(highlightStyle?: any): void; |
| | | openHighlight(highlightStyle?: any, closeLast?: boolean): void; |
| | | /** |
| | | * 清除已选中的高亮 |
| | | * @returns 无 |
| | |
| | | duration?: number; |
| | | complete?: Cesium.Camera.FlightCompleteCallback; |
| | | cancel?: Cesium.Camera.FlightCancelledCallback; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | /** |
| | | * 子图层的个数 |
| | | */ |
| | | readonly length: Int; |
| | | readonly length: number; |
| | | /** |
| | | * 是否可以调整透明度 |
| | | */ |
| | |
| | | */ |
| | | eachLayer(method: (...params: any[]) => any, context: any): this; |
| | | /** |
| | | * 获取所有子图层对象 |
| | | * 获取所有内置子图层对象 |
| | | * @returns } 所有子图层对象 |
| | | */ |
| | | getLayers(): BaseLayer[]; |
| | | /** |
| | | * 获取地图所有的子图层对象(包括pid和id关联的图层) |
| | | * @returns } 所有子图层对象 |
| | | */ |
| | | getChildLayers(): BaseLayer[]; |
| | | /** |
| | | * 根据ID或取图层 |
| | | * @param id - 图层id或uuid |
| | |
| | | * @returns 是否同名 |
| | | */ |
| | | hasLayer(name: string, excludedLayer?: BaseLayer): boolean; |
| | | /** |
| | | * 获取图层内所有数据的 矩形边界值 |
| | | * @param [isFormat = false] - 是否格式化,格式化时示例: { xmin: 73.16895, xmax: 134.86816, ymin: 12.2023, ymax: 54.11485 } |
| | | * @returns isFormat:true时,返回格式化对象,isFormat:false时返回Cesium.Rectangle对象 |
| | | */ |
| | | getRectangle(isFormat?: boolean): Cesium.Rectangle | any; |
| | | /** |
| | | * 飞行定位至图层数据所在的视角 |
| | | * @param [options = {}] - 参数对象: |
| | | * @param options.radius - 点状数据时,相机距离目标点的距离(单位:米) |
| | | * @param [options.scale = 1.8] - 线面数据时,缩放比例,可以控制视角比矩形略大一些,这样效果更友好。 |
| | | * @param [options.duration] - 飞行时间(单位:秒)。如果省略,SDK内部会根据飞行距离计算出理想的飞行时间。 |
| | | * @param [options.complete] - 飞行完成后要执行的函数。 |
| | | * @param [options.cancel] - 飞行取消时要执行的函数。 |
| | | * @param [options.endTransform] - 变换矩阵表示飞行结束时相机所处的参照系。 |
| | | * @param [options.maximumHeight] - 飞行高峰时的最大高度。 |
| | | * @param [options.pitchAdjustHeight] - 如果相机飞得比这个值高,在飞行过程中调整俯仰以向下看,并保持地球在视口。 |
| | | * @param [options.flyOverLongitude] - 地球上的两点之间总有两条路。这个选项迫使相机选择战斗方向飞过那个经度。 |
| | | * @param [options.flyOverLongitudeWeight] - 仅在通过flyOverLongitude指定的lon上空飞行,只要该方式的时间不超过flyOverLongitudeWeight的短途时间。 |
| | | * @param [options.convert = true] - 是否将目的地从世界坐标转换为场景坐标(仅在不使用3D时相关)。 |
| | | * @param [options.easingFunction] - 控制在飞行过程中如何插值时间。 |
| | | * @returns 当前对象本身,可以链式调用 |
| | | */ |
| | | flyTo(options?: { |
| | | radius: number; |
| | | scale?: number; |
| | | duration?: number; |
| | | complete?: Cesium.Camera.FlightCompleteCallback; |
| | | cancel?: Cesium.Camera.FlightCancelledCallback; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | | flyOverLongitudeWeight?: number; |
| | | convert?: boolean; |
| | | easingFunction?: Cesium.EasingFunction.Callback; |
| | | }): this; |
| | | } |
| | | |
| | | /** |
| | |
| | | * @property click - 鼠标单击事件【WMS等动态服务enablePickFeatures:true时,支持单击获取对应的矢量对象】 |
| | | * @property popupOpen - 当存在popup时,popup弹窗打开后 |
| | | * @property popupClose - 当存在popup时,popup弹窗关闭 |
| | | * @property highlightOpen - highlight高亮后 |
| | | * @property highlightClose - highlight关闭后 |
| | | */ |
| | | type EventType = { |
| | | add: string; |
| | |
| | | click: string; |
| | | popupOpen: string; |
| | | popupClose: string; |
| | | highlightOpen: string; |
| | | highlightClose: string; |
| | | }; |
| | | } |
| | | |
| | |
| | | /** |
| | | * 高亮对象。 |
| | | * @param [highlightStyle] - 高亮的样式,具体见各{@link GraphicType}矢量数据的style参数。 |
| | | * @param [closeLast = true] - 是否清除地图上上一次的高亮对象 |
| | | * @returns 无 |
| | | */ |
| | | openHighlight(highlightStyle?: any): void; |
| | | openHighlight(highlightStyle?: any, closeLast?: boolean): void; |
| | | /** |
| | | * 清除已选中的高亮 |
| | | * @returns 无 |
| | |
| | | duration?: number; |
| | | complete?: Cesium.Camera.FlightCompleteCallback; |
| | | cancel?: Cesium.Camera.FlightCancelledCallback; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | rotateCamera(type: MoveType): void; |
| | | /** |
| | | * 相机旋转的类型 |
| | | * @property ENLARGE - 向屏幕中心靠近 |
| | | * @property NARROW - 向屏幕中心远离 |
| | | * @property LEFT_ROTATE - 相机原地左旋转 |
| | | * @property RIGHT_ROTATE - 相机原地右旋转 |
| | | * @property TOP_ROTATE - 相机原地上旋转 |
| | | * @property BOTTOM_ROTATE - 相机原地下旋转 |
| | | */ |
| | | static MoveType: { |
| | | ENLARGE: Int; |
| | | NARROW: Int; |
| | | LEFT_ROTATE: Int; |
| | | RIGHT_ROTATE: Int; |
| | | TOP_ROTATE: Int; |
| | | BOTTOM_ROTATE: Int; |
| | | }; |
| | | static MoveType: MoveType; |
| | | } |
| | | |
| | | /** |
| | | * 地图鼠标事件 统一管理类 |
| | | */ |
| | | declare class MouseEvent { |
| | | /** |
| | | * 鼠标移动事件的延迟毫秒数 |
| | | */ |
| | | moveDelay: number; |
| | | /** |
| | | * 是否开启鼠标移动事件的拾取矢量数据 |
| | | */ |
| | |
| | | /** |
| | | * 获取当前地图层级(概略),一般为0-21层 |
| | | */ |
| | | readonly level: Int; |
| | | readonly level: number; |
| | | /** |
| | | * 是否固定光照, |
| | | * true:可避免gltf、3dtiles模型随时间存在亮度不一致。 |
| | |
| | | */ |
| | | getCenter(): LatLngPoint; |
| | | /** |
| | | * 取相机到屏幕中心点的距离 |
| | | * @returns 相机到屏幕中心点的距离,单位:米 |
| | | */ |
| | | getCameraDistance(): number; |
| | | /** |
| | | * 提取地球当前视域边界,示例:{ xmin: 70, xmax: 140, ymin: 0, ymax: 55, height: 0, } |
| | | * @param [options = {}] - 参数对象: |
| | | * @param [options.formatNum = false] - 是否格式化小数位,只保留6位小数 |
| | | * @param [options.scale = 1] - 通过在每个方向上按给定比例扩展当前边界,0.x时返回缩小的比例边界,大于1时返回放大的边界 |
| | | * @returns 当前视域边界 |
| | | */ |
| | | getExtent(options?: { |
| | | formatNum?: boolean; |
| | | scale?: number; |
| | | }): any; |
| | | /** |
| | | * 截图,导出地图场景图片 |
| | |
| | | * 没有id的图层,会自动使用本方法进行id赋值处理 |
| | | * @returns 图层ID |
| | | */ |
| | | getNextLayerId(): Int; |
| | | getNextLayerId(): number; |
| | | /** |
| | | * 添加图层到地图上 |
| | | * @param layer - 图层对象 |
| | |
| | | duration?: number; |
| | | complete?: Cesium.Camera.FlightCompleteCallback; |
| | | cancel?: Cesium.Camera.FlightCancelledCallback; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | }[], options?: { |
| | | complete?: Cesium.Camera.FlightCompleteCallback; |
| | | cancel?: Cesium.Camera.FlightCancelledCallback; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | duration?: number; |
| | | complete?: Cesium.Camera.FlightCompleteCallback; |
| | | cancel?: Cesium.Camera.FlightCancelledCallback; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | duration?: number; |
| | | complete?: Cesium.Camera.FlightCompleteCallback; |
| | | cancel?: Cesium.Camera.FlightCancelledCallback; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | duration?: number; |
| | | complete?: Cesium.Camera.FlightCompleteCallback; |
| | | cancel?: Cesium.Camera.FlightCancelledCallback; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | clampToGround?: boolean; |
| | | complete?: Cesium.Camera.FlightCompleteCallback; |
| | | cancel?: Cesium.Camera.FlightCancelledCallback; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | }): void; |
| | | /** |
| | | * 清除已高亮的矢量对象 |
| | | * @param [result] - 事件对象 |
| | | * @returns 无 |
| | | */ |
| | | closeHighlight(): void; |
| | | closeHighlight(result?: any): void; |
| | | /** |
| | | * 高亮矢量对象 |
| | | * @param graphic - 矢量对象 |
| | |
| | | * @param options - 参数对象,包括以下: |
| | | * @param options.image - 背景图片URL |
| | | * @param [options.opacity = 1] - 透明度 |
| | | * @param [options.color = Cesium.Color.WHITE] - 颜色 |
| | | */ |
| | | declare class Image2MaterialProperty extends BaseMaterialProperty { |
| | | constructor(options: { |
| | | image: string; |
| | | opacity?: number; |
| | | color?: string | Cesium.Color; |
| | | }); |
| | | /** |
| | | * 获取 材质名称 |
| | |
| | | * @param [options.speed = 2] - 速度,值越大越快 |
| | | * @param [options.percent = 0.04] - 比例 |
| | | * @param [options.alpha = 0.1] - 透明程度 0.0-1.0 |
| | | * @param [options.startTime = 0] - 开始的时间系数 |
| | | */ |
| | | declare class LineFlowColorMaterialProperty extends BaseMaterialProperty { |
| | | constructor(options: { |
| | |
| | | speed?: number; |
| | | percent?: number; |
| | | alpha?: number; |
| | | startTime?: number; |
| | | }); |
| | | /** |
| | | * 获取 材质名称 |
| | |
| | | fill?: boolean; |
| | | color?: string; |
| | | stroke?: boolean; |
| | | strokeColor?: Color; |
| | | strokeColor?: Cesium.Color; |
| | | strokeWidth?: number; |
| | | backgroundColor?: Color; |
| | | backgroundColor?: Cesium.Color; |
| | | outlineWidth?: number; |
| | | outlineColor?: Cesium.Color; |
| | | padding?: number; |
| | |
| | | font_style?: string; |
| | | font?: string; |
| | | fill?: boolean; |
| | | fillColor?: Color; |
| | | fillColor?: Cesium.Color; |
| | | stroke?: boolean; |
| | | strokeColor?: Color; |
| | | strokeColor?: Cesium.Color; |
| | | strokeWidth?: number; |
| | | backgroundColor?: Color; |
| | | backgroundColor?: Cesium.Color; |
| | | outlineWidth?: number; |
| | | outlineColor?: Cesium.Color; |
| | | padding?: number; |
| | |
| | | duration?: number; |
| | | complete?: Cesium.Camera.FlightCompleteCallback; |
| | | cancel?: Cesium.Camera.FlightCancelledCallback; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | * @returns 无 |
| | | */ |
| | | remove(destroy: boolean): void; |
| | | } |
| | | |
| | | /** |
| | | * 视锥体的类型 |
| | | */ |
| | | declare const enum SensorType { |
| | | /** |
| | | * 四棱锥 |
| | | */ |
| | | Rect = 0, |
| | | /** |
| | | * 圆锥 |
| | | */ |
| | | Conic = 1 |
| | | } |
| | | |
| | | /** |
| | |
| | | duration?: number; |
| | | complete?: Cesium.Camera.FlightCompleteCallback; |
| | | cancel?: Cesium.Camera.FlightCancelledCallback; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | duration?: number; |
| | | complete?: Cesium.Camera.FlightCompleteCallback; |
| | | cancel?: Cesium.Camera.FlightCancelledCallback; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | duration?: number; |
| | | complete?: Cesium.Camera.FlightCompleteCallback; |
| | | cancel?: Cesium.Camera.FlightCancelledCallback; |
| | | endTransform?: Matrix4; |
| | | endTransform?: Cesium.Matrix4; |
| | | maximumHeight?: number; |
| | | pitchAdjustHeight?: number; |
| | | flyOverLongitude?: number; |
| | |
| | | }); |
| | | } |
| | | |
| | | declare namespace BaseWidget { |
| | | /** |
| | | * widget 配置参数 |
| | | * @property name - 必须,中文名称,用于标识和弹窗标题。 |
| | | * @property uri - 必须,JS文件路径,路径是相对于widgets目录的路径。如:"widgets/bookmark/widget.js" |
| | | * @property [id] - 定义该插件的唯一标识,方便后续判断。 |
| | | * @property [autoDisable = true] - 激活其他新插件时,是否自动释放本插件 |
| | | * @property [disableOther = true] - 激活本插件时,是否释放其它已激活的插件 |
| | | * @property [group] - 配置group后,同group下的widget互斥,打开任意一个会自动释放其他的 |
| | | * @property [windowOptions] - 存在弹窗的插件的弹窗相关参数配置,更多参数请参考 [layer弹窗API]{@link https://www.layui.com/doc/modules/layer.html} 包括: |
| | | * @property [windowOptions.width] - 窗口宽度,可以是 像素数字(像素值) 或者 字符串(屏幕宽度百分比),示例:200 或 "20%" |
| | | * @property [windowOptions.height] - 窗口高度,可以是 像素数字(像素值) 或者 字符串(屏幕高度百分比),示例:600 或 "50%" |
| | | * @property [windowOptions.position = 'auto'] - 窗口所在位置坐标,配置字符串可选值:auto垂直水平居中,t顶部,b底部,r右边缘,l左边缘,lt左上角,lb左下角,rt右上角,rb右下角;也可以配置对象: |
| | | * @property [windowOptions.position.top] - 位置css的top值,可以是 像素数字(像素值) 或者 字符串(屏幕高度百分比),示例:10 或 "5%" |
| | | * @property [windowOptions.position.bottom] - 位置css的top值,可以是 像素数字(像素值) 或者 字符串(屏幕高度百分比),示例:10 或 "5%" |
| | | * @property [windowOptions.position.left] - 位置css的top值,可以是 像素数字(像素值) 或者 字符串(屏幕宽度百分比),示例:10 或 "5%" |
| | | * @property [windowOptions.position.right] - 位置css的top值,可以是 像素数字(像素值) 或者 字符串(屏幕宽度百分比),示例:10 或 "5%" |
| | | * @property [windowOptions.minHeight] - 限定的窗口最小高度(像素值),默认不限制 |
| | | * @property [windowOptions.maxHeight] - 限定的窗口最大高度(像素值),默认不限制 |
| | | * @property [windowOptions.minWidth] - 限定的窗口最小宽度(像素值),默认不限制 |
| | | * @property [windowOptions.maxWidth] - 限定的窗口最大宽度(像素值),默认不限制 |
| | | * @property [windowOptions.maxmin = true] - 是否可以在弹层右下角拖动来拉伸尺寸 |
| | | * @property [windowOptions.shade = 0] - 遮罩,默认为0不显示,可配置数字0.3透明度的黑色背景('#000'),其他颜色,可以shade: [0.8, '#393D49'] |
| | | * @property [windowOptions.shade = false] - 当shade是存在的,点击弹层外区域后是否关闭弹窗。 |
| | | * @property [windowOptions.closeBtn = 1] - 当为0时,不显示关闭按钮,配置1和2来展示两种风格的关闭按钮 |
| | | * @property [windowOptions.noTitle = false] - 是否不显示标题,为true是不显示标题 |
| | | * @property [openAtStart = false] - 打开系统后是否自动启动本插件 |
| | | * @property [style] - 添加到widget的view中的class样式名 |
| | | * @property [css] - 添加到widget的css值 |
| | | * @property [show = true] - 激活后是否显示弹窗,false时激活后自动隐藏弹窗。 |
| | | * @property [其他] - 传入数据等,定义的任意参数在widget内部方法中都可以通过this.config获取到 |
| | | */ |
| | | type widgetOptions = { |
| | | name: string; |
| | | uri: string; |
| | | id?: string; |
| | | autoDisable?: boolean; |
| | | disableOther?: boolean; |
| | | group?: string; |
| | | windowOptions?: { |
| | | width?: number | string; |
| | | height?: number | string; |
| | | position?: { |
| | | top?: number | string; |
| | | bottom?: number | string; |
| | | left?: number | string; |
| | | right?: number | string; |
| | | }; |
| | | minHeight?: number; |
| | | maxHeight?: number; |
| | | minWidth?: number; |
| | | maxWidth?: number; |
| | | maxmin?: boolean; |
| | | shade?: boolean; |
| | | shade?: boolean; |
| | | closeBtn?: number; |
| | | noTitle?: number; |
| | | }; |
| | | openAtStart?: boolean; |
| | | style?: string; |
| | | css?: any; |
| | | show?: boolean; |
| | | 其他?: any; |
| | | }; |
| | | } |
| | | |
| | | /** |
| | | * widget基础类, |
| | | * 需要继承后使用,不用手动实例化,框架内部自动实例化及相关处理。 |
| | |
| | | * @param options - 配置参数 |
| | | */ |
| | | declare class BaseWidget extends BaseClass { |
| | | constructor(map: Map, options: widget.WidgetOptions); |
| | | constructor(map: Map, options: BaseWidget.widgetOptions); |
| | | /** |
| | | * 获取当前地图 |
| | | */ |
| | |
| | | /** |
| | | * 获取当前配置参数 |
| | | */ |
| | | readonly options: widget.WidgetOptions; |
| | | readonly options: BaseWidget.widgetOptions; |
| | | /** |
| | | * 获取当前配置参数,别名,同options |
| | | */ |
| | | readonly config: widget.WidgetOptions; |
| | | readonly config: BaseWidget.widgetOptions; |
| | | /** |
| | | * 获取当前widget的目录路径 |
| | | */ |
| | |
| | | } |
| | | |
| | | /** |
| | | * 事件类型 枚举(所有事件统一的入口) |
| | | * widget事件类型枚举, mars3d.widget.EventType |
| | | * 【需要引入 mars3d-widget 插件库】 |
| | | */ |
| | | declare const enum EventType { |
| | | declare const enum WidgetEventType { |
| | | /** |
| | | * 添加对象 |
| | | * 在实例初始化之后、创建之前执行 |
| | | */ |
| | | add = "add", |
| | | beforeCreate = "beforeCreate", |
| | | /** |
| | | * 移除对象 |
| | | * 实例创建后执行 |
| | | */ |
| | | remove = "remove", |
| | | created = "created", |
| | | /** |
| | | * 添加矢量数据时[图层上监听时使用] |
| | | * 在activat挂载开始之前调用 |
| | | */ |
| | | addGraphic = "addGraphic", |
| | | beforeActivate = "beforeActivate", |
| | | /** |
| | | * 移除矢量数据时[图层上监听时使用] |
| | | * activate方法调用后 |
| | | */ |
| | | removeGraphic = "removeGraphic", |
| | | activated = "activated", |
| | | /** |
| | | * 添加图层[map上监听时使用] |
| | | * view弹窗构造完成后后调用 |
| | | */ |
| | | addLayer = "addLayer", |
| | | openView = "openView", |
| | | /** |
| | | * 移除图层[map上监听时使用] |
| | | * 实例销毁之前调用 |
| | | */ |
| | | removeLayer = "removeLayer", |
| | | beforeDisable = "beforeDisable", |
| | | /** |
| | | * 更新了对象 |
| | | * 实例销毁完成调用 |
| | | */ |
| | | update = "update", |
| | | disabled = "disabled", |
| | | /** |
| | | * 更新了style对象 |
| | | */ |
| | | updateStyle = "updateStyle", |
| | | /** |
| | | * 更新了attr对象 |
| | | */ |
| | | updateAttr = "updateAttr", |
| | | /** |
| | | * 显示了对象 |
| | | */ |
| | | show = "show", |
| | | /** |
| | | * 隐藏了对象 |
| | | */ |
| | | hide = "hide", |
| | | /** |
| | | * 开始 |
| | | */ |
| | | start = "start", |
| | | /** |
| | | * 变化了 |
| | | */ |
| | | change = "change", |
| | | /** |
| | | * 多个数据异步分析时,完成其中一个时的回调事件 |
| | | */ |
| | | endItem = "endItem", |
| | | /** |
| | | * 多个数据异步分析时,完成所有的回调事件 |
| | | */ |
| | | end = "end", |
| | | /** |
| | | * 完成 |
| | | */ |
| | | stop = "stop", |
| | | /** |
| | | * 完成加载,但未做任何其他处理前 |
| | | * 加载完成 未做任何其他处理前 |
| | | */ |
| | | loadBefore = "loadBefore", |
| | | /** |
| | | * 完成加载,执行所有内部处理后 |
| | | * 加载完成,执行所有内部处理后 |
| | | */ |
| | | load = "load", |
| | | /** |
| | | * 出错了 |
| | | */ |
| | | error = "error", |
| | | /** |
| | | * 完成加载配置信息 |
| | | */ |
| | | loadConfig = "loadConfig", |
| | | /** |
| | | * popup弹窗打开后 |
| | | */ |
| | | popupOpen = "popupOpen", |
| | | /** |
| | | * popup弹窗关闭 |
| | | */ |
| | | popupClose = "popupClose", |
| | | /** |
| | | * tooltip弹窗打开后 |
| | | */ |
| | | tooltipOpen = "tooltipOpen", |
| | | /** |
| | | * tooltip弹窗关闭 |
| | | */ |
| | | tooltipClose = "tooltipClose", |
| | | /** |
| | | * 左键单击 鼠标事件 |
| | | */ |
| | | click = "click", |
| | | /** |
| | | * 左键单击到矢量或模型数据时 鼠标事件 |
| | | */ |
| | | clickGraphic = "clickGraphic", |
| | | /** |
| | | * 左键单击到wms或arcgis瓦片服务的对应矢量数据时 |
| | | */ |
| | | clickTileGraphic = "clickTileGraphic", |
| | | /** |
| | | * 左键单击地图空白(未单击到矢量或模型数据)时 鼠标事件 |
| | | */ |
| | | clickMap = "clickMap", |
| | | /** |
| | | * 左键双击 鼠标事件 |
| | | */ |
| | | dblClick = "dblClick", |
| | | /** |
| | | * 左键鼠标按下 鼠标事件 |
| | | */ |
| | | leftDown = "leftDown", |
| | | /** |
| | | * 左键鼠标按下后释放 鼠标事件 |
| | | */ |
| | | leftUp = "leftUp", |
| | | /** |
| | | * 鼠标移动 鼠标事件 |
| | | */ |
| | | mouseMove = "mouseMove", |
| | | /** |
| | | * 鼠标移动(拾取目标,并延迟处理) 鼠标事件 |
| | | */ |
| | | mouseMoveTarget = "mouseMoveTarget", |
| | | /** |
| | | * 鼠标滚轮滚动 鼠标事件 |
| | | */ |
| | | wheel = "wheel", |
| | | /** |
| | | * 右键单击 鼠标事件 |
| | | */ |
| | | rightClick = "rightClick", |
| | | /** |
| | | * 右键鼠标按下 鼠标事件 |
| | | */ |
| | | rightDown = "rightDown", |
| | | /** |
| | | * 右键鼠标按下后释放 鼠标事件 |
| | | */ |
| | | rightUp = "rightUp", |
| | | /** |
| | | * 中键单击 鼠标事件 |
| | | */ |
| | | middleClick = "middleClick", |
| | | /** |
| | | * 中键鼠标按下 鼠标事件 |
| | | */ |
| | | middleDown = "middleDown", |
| | | /** |
| | | * 中键鼠标按下后释放 鼠标事件 |
| | | */ |
| | | middleUp = "middleUp", |
| | | /** |
| | | * 在触摸屏上两指缩放开始 鼠标事件 |
| | | */ |
| | | pinchStart = "pinchStart", |
| | | /** |
| | | * 在触摸屏上两指缩放结束 鼠标事件 |
| | | */ |
| | | pinchEnd = "pinchEnd", |
| | | /** |
| | | * 在触摸屏上两指移动 鼠标事件 |
| | | */ |
| | | pinchMove = "pinchMove", |
| | | /** |
| | | * 鼠标按下 [左中右3键都触发] 鼠标事件 |
| | | */ |
| | | mouseDown = "mouseDown", |
| | | /** |
| | | * 鼠标按下后释放 [左中右3键都触发] 鼠标事件 |
| | | */ |
| | | mouseUp = "mouseUp", |
| | | /** |
| | | * 鼠标移入 鼠标事件 |
| | | */ |
| | | mouseOver = "mouseOver", |
| | | /** |
| | | * 鼠标移出 鼠标事件 |
| | | */ |
| | | mouseOut = "mouseOut", |
| | | /** |
| | | * 按键按下 键盘事件 |
| | | */ |
| | | keydown = "keydown", |
| | | /** |
| | | * 按键按下后释放 键盘事件 |
| | | */ |
| | | keyup = "keyup", |
| | | /** |
| | | * 开始绘制 标绘事件 |
| | | */ |
| | | drawStart = "drawStart", |
| | | /** |
| | | * 正在移动鼠标中,绘制过程中鼠标移动了点 标绘事件 |
| | | */ |
| | | drawMouseMove = "drawMouseMove", |
| | | /** |
| | | * 绘制过程中增加了点 标绘事件 |
| | | */ |
| | | drawAddPoint = "drawAddPoint", |
| | | /** |
| | | * 绘制过程中删除了最后一个点 标绘事件 |
| | | */ |
| | | drawRemovePoint = "drawRemovePoint", |
| | | /** |
| | | * 创建完成 标绘事件 |
| | | */ |
| | | drawCreated = "drawCreated", |
| | | /** |
| | | * 开始编辑 标绘事件 |
| | | */ |
| | | editStart = "editStart", |
| | | /** |
| | | * 移动鼠标按下左键(LEFT_DOWN)标绘事件 |
| | | */ |
| | | editMouseDown = "editMouseDown", |
| | | /** |
| | | * 正在移动鼠标中,正在编辑拖拽修改点中(MOUSE_MOVE) 标绘事件 |
| | | */ |
| | | editMouseMove = "editMouseMove", |
| | | /** |
| | | * 编辑修改了点(LEFT_UP)标绘事件 |
| | | */ |
| | | editMovePoint = "editMovePoint", |
| | | /** |
| | | * 编辑删除了点 标绘事件 |
| | | */ |
| | | editRemovePoint = "editRemovePoint", |
| | | /** |
| | | * 图上编辑修改了相关style属性 标绘事件 |
| | | */ |
| | | editStyle = "editStyle", |
| | | /** |
| | | * 停止编辑 标绘事件 |
| | | */ |
| | | editStop = "editStop", |
| | | /** |
| | | * 标绘事件 |
| | | */ |
| | | move = "move", |
| | | /** |
| | | * 3dtiles模型,模型瓦片初始化完成 |
| | | * 该回调只执行一次 |
| | | */ |
| | | initialTilesLoaded = "initialTilesLoaded", |
| | | /** |
| | | * 3dtiles模型,当前批次模型加载完成 |
| | | * 该回调会执行多次,视角变化后重新加载一次完成后都会回调 |
| | | */ |
| | | allTilesLoaded = "allTilesLoaded", |
| | | /** |
| | | * 栅格瓦片图层,添加单个瓦片,开始加载瓦片(请求前) |
| | | */ |
| | | addTile = "addTile", |
| | | /** |
| | | * 栅格瓦片图层,添加单个瓦片 加载瓦片完成 |
| | | */ |
| | | addTileSuccess = "addTileSuccess", |
| | | /** |
| | | * 栅格瓦片图层,添加单个瓦片 加载瓦片出错了 |
| | | */ |
| | | addTileError = "addTileError", |
| | | /** |
| | | * 栅格瓦片图层,移除单个瓦片 |
| | | */ |
| | | removeTile = "removeTile", |
| | | /** |
| | | * 相机开启移动前 场景事件 |
| | | */ |
| | | cameraMoveStart = "cameraMoveStart", |
| | | /** |
| | | * 相机移动完成后 场景事件 |
| | | */ |
| | | cameraMoveEnd = "cameraMoveEnd", |
| | | /** |
| | | * 相机位置完成 场景事件 |
| | | */ |
| | | cameraChanged = "cameraChanged", |
| | | /** |
| | | * 场景更新前 场景事件 |
| | | */ |
| | | preUpdate = "preUpdate", |
| | | /** |
| | | * 场景更新后 场景事件 |
| | | */ |
| | | postUpdate = "postUpdate", |
| | | /** |
| | | * 场景渲染前 场景事件 |
| | | */ |
| | | preRender = "preRender", |
| | | /** |
| | | * 场景渲染后 场景事件 |
| | | */ |
| | | postRender = "postRender", |
| | | /** |
| | | * 场景渲染失败(需要刷新页面) |
| | | */ |
| | | renderError = "renderError", |
| | | /** |
| | | * 场景模式(2D/3D/哥伦布)变换前 场景事件 |
| | | */ |
| | | morphStart = "morphStart", |
| | | /** |
| | | * 完成场景模式(2D/3D/哥伦布)变换 场景事件 |
| | | */ |
| | | morphComplete = "morphComplete", |
| | | /** |
| | | * 时钟跳动 场景事件 |
| | | */ |
| | | clockTick = "clockTick" |
| | | load = "load" |
| | | } |
| | | |
| | | /** |
| | |
| | | * @returns 无 |
| | | */ |
| | | function init(map: Map, widgetcfg?: { |
| | | defaultOptions?: widget.WidgetOptions; |
| | | openAtStart?: widget.WidgetOptions[]; |
| | | widgets?: widget.WidgetOptions[]; |
| | | defaultOptions?: BaseWidget.widgetOptions; |
| | | openAtStart?: BaseWidget.widgetOptions[]; |
| | | widgets?: BaseWidget.widgetOptions[]; |
| | | version?: string; |
| | | debugger?: boolean; |
| | | }, _basePath?: string): void; |
| | |
| | | */ |
| | | function activate(item: { |
| | | map?: Map; |
| | | }, noDisableOther?: boolean): widget.WidgetOptions; |
| | | }, noDisableOther?: boolean): BaseWidget.widgetOptions; |
| | | /** |
| | | * 获取指定的widget配置信息 |
| | | * @param uri - widget的uri 或 id |
| | | * @returns widget配置信息 |
| | | */ |
| | | function getWidget(uri: string): widget.WidgetOptions; |
| | | function getWidget(uri: string): BaseWidget.widgetOptions; |
| | | /** |
| | | * 获取指定的widget 对应的实例化对象 |
| | | * @param uri - widget的uri 或 id |
| | |
| | | * @param context - 侦听器的上下文(this关键字将指向的对象)。 |
| | | * @returns 无 |
| | | */ |
| | | function on(types: EventType | EventType[], fn: (...params: any[]) => any, context: any): void; |
| | | function on(types: WidgetEventType | WidgetEventType[], fn: (...params: any[]) => any, context: any): void; |
| | | /** |
| | | * 解除绑定指定类型事件监听器 |
| | | * @param types - 事件类型 |
| | |
| | | * @param context - 侦听器的上下文(this关键字将指向的对象)。 |
| | | * @returns 无 |
| | | */ |
| | | function off(types: EventType | EventType[], fn: (...params: any[]) => any, context: any): void; |
| | | function off(types: WidgetEventType | WidgetEventType[], fn: (...params: any[]) => any, context: any): void; |
| | | /** |
| | | * 触发指定类型的事件。 |
| | | * @param type - 事件类型 |
| | |
| | | * @param [propagate = null] - 将事件传播给父类 (用addEventParent设置) |
| | | * @returns 无 |
| | | */ |
| | | function fire(type: EventType, data: any, propagate?: BaseClass): void; |
| | | function fire(type: WidgetEventType, data: any, propagate?: BaseClass): void; |
| | | /** |
| | | * 绑定一次性执行的指定类型事件监听器 |
| | | * 与on类似,监听器只会被触发一次,然后被删除。 |
| | |
| | | * @param context - 侦听器的上下文(this关键字将指向的对象)。 |
| | | * @returns 无 |
| | | */ |
| | | function once(types: EventType | EventType[], fn: (...params: any[]) => any, context: any): void; |
| | | function once(types: WidgetEventType | WidgetEventType[], fn: (...params: any[]) => any, context: any): void; |
| | | /** |
| | | * 是否有绑定指定的事件 |
| | | * @param type - 事件类型 |
| | | * @param [propagate = null] - 是否判断指定的父类 (用addEventParent设置的) |
| | | * @returns 是否存在 |
| | | */ |
| | | function listens(type: EventType, propagate?: BaseClass): boolean; |
| | | function listens(type: WidgetEventType, propagate?: BaseClass): boolean; |
| | | } |
| | | |
| | | /** |
| | |
| | | readonly graphics: BaseGraphic[]; |
| | | /** |
| | | * 测量 空间长度 |
| | | * @param opts - 控制参数 |
| | | * @param [opts.style] - 路线的样式 |
| | | * @param [opts.unit = 'auto'] - 计量单位,{@link MeasureUtil#formatDistance}可选值:auto、m、km、mile、zhang 。auto时根据距离值自动选用k或km |
| | | * @param options - 控制参数 |
| | | * @param [options.style] - 路线的样式 |
| | | * @param [options.unit = 'auto'] - 计量单位,{@link MeasureUtil#formatDistance}可选值:auto、m、km、mile、zhang 。auto时根据距离值自动选用k或km |
| | | * @param [options.maxPointNum = 9999] - 绘制时,最多允许点的个数 |
| | | * @param [options.addHeight = 0] - 在draw绘制时,在绘制点的基础上增加的高度值 |
| | | * @param [options.showAddText = true] - 是否显示每一段的增加部分距离,如(+10.1km) |
| | | * @returns 长度测量控制类 对象 |
| | | */ |
| | | distance(opts: { |
| | | distance(options: { |
| | | style?: PolylineEntity.StyleOptions; |
| | | unit?: string; |
| | | maxPointNum?: number; |
| | | addHeight?: number; |
| | | showAddText?: boolean; |
| | | }): MeasureDistance; |
| | | /** |
| | | * 测量 贴地长度 |
| | | * @param opts - 控制参数 |
| | | * @param [opts.style] - 路线的样式 |
| | | * @param [opts.unit = 'auto'] - 计量单位,{@link MeasureUtil#formatDistance}可选值:auto、m、km、mile、zhang 。auto时根据距离值自动选用k或km |
| | | * @param options - 控制参数 |
| | | * @param [options.style] - 路线的样式 |
| | | * @param [options.unit = 'auto'] - 计量单位,{@link MeasureUtil#formatDistance}可选值:auto、m、km、mile、zhang 。auto时根据距离值自动选用k或km |
| | | * @param [options.maxPointNum = 9999] - 绘制时,最多允许点的个数 |
| | | * @param [options.addHeight = 0] - 在draw绘制时,在绘制点的基础上增加的高度值 |
| | | * @param [options.showAddText = true] - 是否显示每一段的增加部分距离,如(+10.1km) |
| | |
| | | * @param [options.has3dtiles = auto] - 是否在3dtiles模型上分析(模型分析较慢,按需开启),默认内部根据点的位置自动判断(但可能不准) |
| | | * @returns 贴地长度测量控制类 对象 |
| | | */ |
| | | distanceSurface(opts: { |
| | | distanceSurface(options: { |
| | | style?: PolylineEntity.StyleOptions; |
| | | unit?: string; |
| | | maxPointNum?: number; |
| | | addHeight?: number; |
| | | showAddText?: boolean; |
| | | splitNum?: number; |
| | | has3dtiles?: boolean; |
| | | }): MeasureDistanceSurface; |
| | | /** |
| | | * 剖面分析,测量线插值点的高程数据 |
| | | * @param opts - 控制参数 |
| | | * @param [opts.style] - 路线的样式 |
| | | * @param [opts.unit = 'auto'] - 计量单位,{@link MeasureUtil#formatDistance}可选值:auto、m、km、mile、zhang 。auto时根据距离值自动选用k或km |
| | | * @param options - 控制参数 |
| | | * @param [options.style] - 路线的样式 |
| | | * @param [options.unit = 'auto'] - 计量单位,{@link MeasureUtil#formatDistance}可选值:auto、m、km、mile、zhang 。auto时根据距离值自动选用k或km |
| | | * @param [options.maxPointNum = 9999] - 绘制时,最多允许点的个数 |
| | | * @param [options.addHeight = 0] - 在draw绘制时,在绘制点的基础上增加的高度值 |
| | | * @param [options.splitNum = 200] - 插值数,将线段分割的个数 |
| | | * @param [options.has3dtiles = auto] - 是否在3dtiles模型上分析(模型分析较慢,按需开启),默认内部根据点的位置自动判断(但可能不准) |
| | | * @returns 剖面分析控制类 对象 |
| | | */ |
| | | section(opts: { |
| | | section(options: { |
| | | style?: PolylineEntity.StyleOptions; |
| | | unit?: string; |
| | | maxPointNum?: number; |
| | | addHeight?: number; |
| | | splitNum?: number; |
| | | has3dtiles?: boolean; |
| | | }): MeasureDistanceSection; |
| | | /** |
| | | * 面积测量(水平面) |
| | | * @param opts - 控制参数 |
| | | * @param [opts.style] - 面的样式 |
| | | * @param [opts.unit = 'auto'] - 计量单位,{@link MeasureUtil#formatArea}可选值:auto、m、km、mu、ha 。auto时根据面积值自动选用k或km |
| | | * @param options - 控制参数 |
| | | * @param [options.style] - 面的样式 |
| | | * @param [options.unit = 'auto'] - 计量单位,{@link MeasureUtil#formatArea}可选值:auto、m、km、mu、ha 。auto时根据面积值自动选用k或km |
| | | * @returns 面积测量控制类 对象 |
| | | */ |
| | | area(opts: { |
| | | area(options: { |
| | | style?: PolygonEntity.StyleOptions; |
| | | unit?: string; |
| | | }): MeasureArea; |
| | | /** |
| | | * 贴地面积测量 |
| | | * @param opts - 控制参数 |
| | | * @param [opts.style] - 面的样式 |
| | | * @param [opts.unit = 'auto'] - 计量单位,{@link MeasureUtil#formatArea}可选值:auto、m、km、mu、ha 。auto时根据面积值自动选用k或km |
| | | * @param options - 控制参数 |
| | | * @param [options.style] - 面的样式 |
| | | * @param [options.unit = 'auto'] - 计量单位,{@link MeasureUtil#formatArea}可选值:auto、m、km、mu、ha 。auto时根据面积值自动选用k或km |
| | | * @param [options.splitNum = 10] - 插值数,将面分割的网格数 |
| | | * @param [options.has3dtiles = auto] - 是否在3dtiles模型上分析(模型分析较慢,按需开启),默认内部根据点的位置自动判断(但可能不准) |
| | | * @returns 面积测量控制类 对象 |
| | | */ |
| | | areaSurface(opts: { |
| | | areaSurface(options: { |
| | | style?: PolygonEntity.StyleOptions; |
| | | unit?: string; |
| | | splitNum?: number; |
| | | has3dtiles?: boolean; |
| | | }): MeasureArea; |
| | | /** |
| | | * 体积测量(方量分析) |
| | | * @param opts - 控制参数 |
| | | * @param [opts.style] - 路线的样式 |
| | | * @param [opts.unit = 'auto'] - 计量单位,{@link MeasureUtil#formatArea}可选值:auto、m、km、mu、ha 。auto时根据面积值自动选用k或km |
| | | * @param options - 控制参数 |
| | | * @param [options.style] - 路线的样式 |
| | | * @param [options.unit = 'auto'] - 计量单位,{@link MeasureUtil#formatArea}可选值:auto、m、km、mu、ha 。auto时根据面积值自动选用k或km |
| | | * @param [options.splitNum = 10] - 插值数,将面分割的网格数 |
| | | * @param [options.has3dtiles = auto] - 是否在3dtiles模型上分析(模型分析较慢,按需开启),默认内部根据点的位置自动判断(但可能不准) |
| | | * @param [options.minHeight] - 可以指定最低高度(单位:米) |
| | |
| | | * @param [options.height] - 可以指定基准面高度(单位:米),默认是绘制后的最低高度值 |
| | | * @returns 体积测量控制类 对象 |
| | | */ |
| | | volume(opts: { |
| | | volume(options: { |
| | | style?: PolygonEntity.StyleOptions; |
| | | unit?: string; |
| | | splitNum?: number; |
| | | has3dtiles?: boolean; |
| | | minHeight?: number; |
| | | maxHeight?: number; |
| | | height?: number; |
| | | }): MeasureVolume; |
| | | /** |
| | | * 高度测量 |
| | | * @param opts - 控制参数 |
| | | * @param [opts.style] - 路线的样式 |
| | | * @param [opts.unit = 'auto'] - 计量单位,{@link MeasureUtil#formatDistance}可选值:auto、m、km、mile、zhang 。auto时根据距离值自动选用k或km |
| | | * @param options - 控制参数 |
| | | * @param [options.style] - 路线的样式 |
| | | * @param [options.unit = 'auto'] - 计量单位,{@link MeasureUtil#formatDistance}可选值:auto、m、km、mile、zhang 。auto时根据距离值自动选用k或km |
| | | * @returns 高度测量控制类 对象 |
| | | */ |
| | | height(opts: { |
| | | height(options: { |
| | | style?: PolylineEntity.StyleOptions; |
| | | unit?: string; |
| | | }): MeasureHeight; |
| | | /** |
| | | * 三角高度测量, |
| | | * 包括水平距离、空间距离、高度差。 |
| | | * @param opts - 控制参数 |
| | | * @param [opts.style] - 路线的样式 |
| | | * @param [opts.unit = 'auto'] - 计量单位,{@link MeasureUtil#formatDistance}可选值:auto、m、km、mile、zhang 。auto时根据距离值自动选用k或km |
| | | * @param options - 控制参数 |
| | | * @param [options.style] - 路线的样式 |
| | | * @param [options.unit = 'auto'] - 计量单位,{@link MeasureUtil#formatDistance}可选值:auto、m、km、mile、zhang 。auto时根据距离值自动选用k或km |
| | | * @returns 三角高度测量控制类 对象 |
| | | */ |
| | | heightTriangle(opts: { |
| | | heightTriangle(options: { |
| | | style?: PolylineEntity.StyleOptions; |
| | | unit?: string; |
| | | }): MeasureHeightTriangle; |
| | | /** |
| | | * 角度测量 |
| | | * @param opts - 控制参数 |
| | | * @param [opts.style] - 路线的样式,默认为箭头线 |
| | | * @param options - 控制参数 |
| | | * @param [options.style] - 路线的样式,默认为箭头线 |
| | | * @returns 角度测量控制类 对象 |
| | | */ |
| | | angle(opts: { |
| | | angle(options: { |
| | | style?: PolylineEntity.StyleOptions; |
| | | }): MeasureAngle; |
| | | /** |
| | | * 坐标测量 |
| | | * @param opts - 控制参数 |
| | | * @param [opts.style] - 点的样式 |
| | | * @param options - 控制参数 |
| | | * @param [options.style] - 点的样式 |
| | | * @returns 坐标测量控制类 对象 |
| | | */ |
| | | point(opts: { |
| | | point(options: { |
| | | style?: PointEntity.StyleOptions; |
| | | }): MeasurePoint; |
| | | /** |
| | |
| | | id?: string | number; |
| | | enabled?: boolean; |
| | | alpha?: number; |
| | | color?: Color; |
| | | color?: Cesium.Color; |
| | | }); |
| | | /** |
| | | * 控制球体透明度的Cesium内部对象 |
| | |
| | | * @param [options.spacing = 100.0] - 等高线 间隔(单位:米) |
| | | * @param [options.width = 1.5] - 等高线 线宽(单位:像素) |
| | | * @param [options.color = Cesium.Color.RED] - 等高线 颜色 |
| | | * @param [options.shadingType = 'none'] - 地表渲染效果,可选值: 无nono, 高程 elevation, 坡度slope, 坡向aspect |
| | | * @param [options.shadingType = 'none'] - 地表渲染效果,可选值: 无none, 高程 elevation, 坡度slope, 坡向aspect |
| | | * @param [options.colorScheme] - 地表渲染配色方案,默认值为: |
| | | * { |
| | | * elevation: { |
| | |
| | | contourShow?: boolean; |
| | | spacing?: number; |
| | | width?: number; |
| | | color?: Cesium.Color; |
| | | color?: Cesium.Color | string; |
| | | shadingType?: string; |
| | | colorScheme?: any; |
| | | showElseArea?: boolean; |
| | |
| | | */ |
| | | contourShow: boolean; |
| | | /** |
| | | * 地表渲染效果,可选值: 无nono, 高程 elevation, 坡度slope, 坡向aspect |
| | | * 地表渲染效果,可选值: 无none, 高程 elevation, 坡度slope, 坡向aspect |
| | | */ |
| | | shadingType: string; |
| | | /** |
| | |
| | | /** |
| | | * 等高线 颜色 |
| | | */ |
| | | color: Cesium.Color; |
| | | color: Cesium.Color | string; |
| | | /** |
| | | * 清除数据 |
| | | * @returns 无 |
| | |
| | | * @param options - 参数对象,包括以下: |
| | | * @param [options.id = uuid()] - 对象的id标识 |
| | | * @param [options.enabled = true] - 对象的启用状态 |
| | | * @param [positions] - 坐标位置数组,只显示单个区域【单个区域场景时使用】 |
| | | * @param [options.positions] - 坐标位置数组,只显示单个区域【单个区域场景时使用】 |
| | | * @param [options.speed] - 淹没速度 |
| | | * @param [options.minHeight] - 淹没起始的海拔高度(单位:米) |
| | | * @param [options.maxHeight] - 淹没结束的海拔高度(单位:米) |
| | |
| | | constructor(options: { |
| | | id?: string | number; |
| | | enabled?: boolean; |
| | | positions?: any[][] | String[] | LatLngPoint[] | Cesium.Cartesian3[]; |
| | | speed?: number; |
| | | minHeight?: number; |
| | | maxHeight?: number; |
| | | showElseArea?: boolean; |
| | | }, positions?: any[][] | String[] | LatLngPoint[] | Cesium.Cartesian3[]); |
| | | }); |
| | | /** |
| | | * 淹没高度(单位:米) |
| | | */ |
| | |
| | | * @param options - 参数对象,包括以下: |
| | | * @param [options.id = uuid()] - 对象的id标识 |
| | | * @param [options.enabled = true] - 对象的启用状态 |
| | | * @param [positions] - 坐标位置数组,只显示单个区域【单个区域场景时使用】 |
| | | * @param [options.positions] - 坐标位置数组,只显示单个区域【单个区域场景时使用】 |
| | | * @param [options.clipOutSide = false] - 是否外切开挖 |
| | | * @param [options.image] - 开挖区域的井墙面贴图URL。未传入该值时,不显示开挖区域的井。 |
| | | * @param [options.imageBottom] - 当显示开挖区域的井时,井底面贴图URL |
| | |
| | | constructor(options: { |
| | | id?: string | number; |
| | | enabled?: boolean; |
| | | positions?: any[][] | String[] | LatLngPoint[] | Cesium.Cartesian3[]; |
| | | clipOutSide?: boolean; |
| | | image?: string; |
| | | imageBottom?: string; |
| | | diffHeight?: number; |
| | | }, positions?: any[][] | String[] | LatLngPoint[] | Cesium.Cartesian3[], splitNum?: number); |
| | | }, splitNum?: number); |
| | | /** |
| | | * 是否外切开挖 |
| | | */ |
| | |
| | | * @param options - 参数对象,包括以下: |
| | | * @param [options.id = uuid()] - 对象的id标识 |
| | | * @param [options.enabled = true] - 对象的启用状态 |
| | | * @param [positions] - 坐标位置数组,只显示单个区域【单个区域场景时使用】 |
| | | * @param [options.positions] - 坐标位置数组,只显示单个区域【单个区域场景时使用】 |
| | | */ |
| | | declare class TerrainEditBase extends BaseThing { |
| | | constructor(options: { |
| | | id?: string | number; |
| | | enabled?: boolean; |
| | | }, positions?: any[][] | String[] | LatLngPoint[] | Cesium.Cartesian3[]); |
| | | positions?: any[][] | String[] | LatLngPoint[] | Cesium.Cartesian3[]; |
| | | }); |
| | | /** |
| | | * 区域 列表 |
| | | */ |
| | |
| | | /** |
| | | * 已添加的区域个数 |
| | | */ |
| | | readonly length: Int; |
| | | readonly length: number; |
| | | /** |
| | | * 清除所有区域 |
| | | * @returns 无 |
| | |
| | | * @param options - 参数对象,包括以下: |
| | | * @param [options.id = uuid()] - 对象的id标识 |
| | | * @param [options.enabled = true] - 对象的启用状态 |
| | | * @param [positions] - 开挖区域的 坐标位置数组 |
| | | * @param [options.positions] - 开挖区域的 坐标位置数组 |
| | | * @param [options.clipOutSide = false] - 是否外切开挖 |
| | | * @param [options.image] - 开挖区域的井墙面贴图URL。未传入该值时,不显示开挖区域的井。 |
| | | * @param [options.imageBottom] - 当显示开挖区域的井时,井底面贴图URL |
| | |
| | | constructor(options: { |
| | | id?: string | number; |
| | | enabled?: boolean; |
| | | positions?: any[][] | String[] | LatLngPoint[] | Cesium.Cartesian3[]; |
| | | clipOutSide?: boolean; |
| | | image?: string; |
| | | imageBottom?: string; |
| | | diffHeight?: number; |
| | | }, positions?: any[][] | String[] | LatLngPoint[] | Cesium.Cartesian3[], splitNum?: number); |
| | | }, splitNum?: number); |
| | | /** |
| | | * 开挖区域的 坐标位置数组 |
| | | */ |
| | |
| | | */ |
| | | graphic: ModelEntity; |
| | | /** |
| | | * 获取当前转换计算模型矩阵。如果方向或位置未定义,则返回undefined。 |
| | | * 获取当前转换计算模型逆矩阵, |
| | | * 用于 局部坐标系 与 世界坐标系 的转换。 |
| | | */ |
| | | readonly matrix: Cesium.Matrix4; |
| | | readonly inverseMatrix: Cesium.Matrix4; |
| | | } |
| | | |
| | | declare namespace ModelPlanClip { |
| | |
| | | */ |
| | | tileset: Cesium.Cesium3DTileset; |
| | | /** |
| | | * 获取当前转换计算模型矩阵。如果方向或位置未定义,则返回undefined。 |
| | | * 获取当前转换计算模型逆矩阵, |
| | | * 用于 局部坐标系 与 世界坐标系 的转换。 |
| | | */ |
| | | readonly matrix: Cesium.Matrix4; |
| | | readonly inverseMatrix: Cesium.Matrix4; |
| | | /** |
| | | * 坐标位置数组,只显示单个区域【单个区域场景时使用】 |
| | | */ |
| | |
| | | /** |
| | | * 已添加的区域个数 |
| | | */ |
| | | readonly length: Int; |
| | | readonly length: number; |
| | | /** |
| | | * 清除分析 |
| | | * @returns 无 |
| | |
| | | */ |
| | | readonly planes: Cesium.ClippingPlaneCollection; |
| | | /** |
| | | * 获取当前转换计算模型矩阵。如果方向或位置未定义,则返回undefined。 |
| | | * 获取当前转换计算模型逆矩阵, |
| | | * 用于 局部坐标系 与 世界坐标系 的转换。 |
| | | */ |
| | | readonly matrix: Cesium.Matrix4; |
| | | readonly inverseMatrix: Cesium.Matrix4; |
| | | /** |
| | | * 更新最后一个面的 裁剪距离 (单位:米) |
| | | */ |
| | |
| | | Y, |
| | | YR |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * 通用材质 转换处理类 |
| | | */ |
| | | declare class BaseMaterialConver extends BaseOptsConver { |
| | | } |
| | | |
| | | /** |
| | | * 图片材质 转换处理类 |
| | | */ |
| | | declare class ImageOptsConver extends BaseMaterialConver { |
| | | } |
| | | |
| | | /** |
| | | * 矢量数据style转换处理基类 |
| | | */ |
| | | declare class BaseStyleConver extends BaseOptsConver { |
| | | } |
| | | |
| | | /** |
| | | * Polygon矢量数据style转换处理类 |
| | | */ |
| | | declare class PolygonStyleConver extends BaseStyleConver { |
| | | /** |
| | | * style样式属性赋值到 entity |
| | | * @param style - 样式 |
| | | * @param entityGraphic - 矢量数据对应的 Cesium内部对象 |
| | | * @param isEntity - 是否为entity |
| | | * @returns 矢量数据所需的Cesium内部对象 |
| | | */ |
| | | static toCesiumVal(style: PolygonEntity.StyleOptions, entityGraphic: Cesium.PolygonGraphics | null, isEntity: boolean): Cesium.PolygonGraphics; |
| | | } |
| | | |
| | | /** |
| | |
| | | * @param positions - 坐标数组 |
| | | * @returns 距离(单位:米) |
| | | */ |
| | | function getDistance(positions: Cesium.Cartesian3[]): number; |
| | | function getDistance(positions: Cesium.Cartesian3[] | LatLngPoint[]): number; |
| | | /** |
| | | * 求坐标数组的 距离(地球表面弧度的), |
| | | * 比如北京到纽约(不能穿过球心,是贴地表的线的距离) |
| | | * @param positions - 坐标数组 |
| | | * @returns 距离(单位:米) |
| | | */ |
| | | function getSurfaceDistance(positions: Cesium.Cartesian3[]): number; |
| | | function getSurfaceDistance(positions: Cesium.Cartesian3[] | LatLngPoint[]): number; |
| | | /** |
| | | * 异步计算贴地距离中,每计算完成2个点之间的距离后 的回调方法 |
| | | * @param options - 参数对象,具有以下属性: |
| | |
| | | * @param options.callback - 异步计算贴地距离完成 的回调方法 |
| | | * @returns 无 |
| | | */ |
| | | function getClampDistance(positions: Cesium.Cartesian3[], options: { |
| | | function getClampDistance(positions: Cesium.Cartesian3[] | LatLngPoint[], options: { |
| | | scene: Cesium.Scene; |
| | | splitNum?: number; |
| | | has3dtiles?: boolean; |
| | |
| | | * @param positions - 坐标数组 |
| | | * @returns 面积,单位:平方米 |
| | | */ |
| | | function getArea(positions: Cesium.Cartesian3[]): number; |
| | | function getArea(positions: Cesium.Cartesian3[] | LatLngPoint[]): number; |
| | | /** |
| | | * 计算三角形面积(空间平面) |
| | | * @param pos1 - 三角形顶点坐标1 |
| | |
| | | * @param options.callback - 异步计算贴地距离完成 的回调方法 |
| | | * @returns 仅 asyn:false 时返回面积,单位:平方米 |
| | | */ |
| | | function getClampArea(positions: Cesium.Cartesian3[], options: { |
| | | function getClampArea(positions: Cesium.Cartesian3[] | LatLngPoint[], options: { |
| | | asyn: boolean; |
| | | scene: Cesium.Scene; |
| | | splitNum?: number; |
| | |
| | | * 获取 坐标 的 贴地(或贴模型)高度 |
| | | * @example |
| | | * var position = graphic.position |
| | | * position = mars3d.PointUtil.getSurfaceHeight(map.scene, position, { |
| | | * mars3d.PointUtil.getSurfaceHeight(map.scene, position, { |
| | | * asyn: true, //是否异步求准确高度 |
| | | * has3dtiles: true, //是否先求贴模型上(无模型时改为false,提高效率) |
| | | * callback: function (newHeight, cartOld) { |
| | |
| | | * @param [splitNum = 10] - splitNum网格数 |
| | | * @returns granularity值 |
| | | */ |
| | | function getGranularity(positions: Cesium.Cartesian3[], splitNum?: Int): number; |
| | | function getGranularity(positions: Cesium.Cartesian3[], splitNum?: number): number; |
| | | /** |
| | | * 面内进行贴地(或贴模型)插值, 返回三角网等计算结果 的回调方法 |
| | | * @param [options = {}] - 参数对象: |
| | |
| | | * @returns 边线上的坐标点数组 |
| | | */ |
| | | function getEllipseOuterPositions(options?: { |
| | | position: Cesium.Cartesian3; |
| | | position: Cesium.Cartesian3 | LatLngPoint; |
| | | radius: number; |
| | | semiMajorAxis: number; |
| | | semiMinorAxis: number; |
| | |
| | | * @param [digits = 6] - 经纬度保留的小数位数 |
| | | * @returns 返回经纬度值,示例: { xmin: 73.16895, xmax: 134.86816, ymin: 12.2023, ymax: 54.11485 } |
| | | */ |
| | | function formatRectangle(rectangle: Cesium.Rectangle, digits?: Int): any; |
| | | function formatRectangle(rectangle: Cesium.Rectangle, digits?: number): any; |
| | | /** |
| | | * 获取 坐标数组 的 矩形边界值 |
| | | * @param positions - 坐标数组 |
| | |
| | | originX?: number; |
| | | originY?: number; |
| | | }): Cesium.Cartesian3[]; |
| | | /** |
| | | * 判断点是否 多边形内 |
| | | * @param position - 需要判断的点 |
| | | * @param coordinates - 多边形的边界点 |
| | | * @returns 是否在多边形内 |
| | | */ |
| | | function isInPoly(position: Cesium.Cartesian3 | LatLngPoint, coordinates: Cesium.Cartesian3[] | LatLngPoint[]): boolean; |
| | | /** |
| | | * 求贝塞尔曲线坐标 |
| | | * @param positions - 坐标数组 |
| | |
| | | * @param [digits = 0] - 小数位数 |
| | | * @returns 返回digits指定小数位的数字 |
| | | */ |
| | | function formatNum(num: number, digits?: Int): number; |
| | | function formatNum(num: number, digits?: number): number; |
| | | /** |
| | | * 按指定长度,对数字进行补零,返回指定长度的字符串 |
| | | * @param numStr - 数字对象,示例:1234 |
| | | * @param n - 指定长度,示例:8 |
| | | * @returns 补零后的指定长度的字符串,示例:'00001234' |
| | | */ |
| | | function padLeft0(numStr: number | string, n: Int): string; |
| | | function padLeft0(numStr: number | string, n: number): string; |
| | | /** |
| | | * 根据空格分割字符串,并返回字符串数组(会自动去掉首位空格) |
| | | * @param str - 字符串 |
| | |
| | | * @param [level = 5] - 拷贝的层级最大深度,避免死循环 |
| | | * @returns 克隆后的对象 |
| | | */ |
| | | function clone(obj: any, removeKeys?: String[], level?: Int): any; |
| | | function clone(obj: any, removeKeys?: String[], level?: number): any; |
| | | /** |
| | | * 随机获取数组中的一个元素 |
| | | * @param arr - 数组 |
| | |
| | | * @param feature - geojson单个Feature对象 |
| | | * @param [options = {}] - 参数,包括: |
| | | * @param [options.type] - 转为指定的类型 |
| | | * @param [options.crs] - 原始数据的坐标系,如'EPSG:3857' (可以从 {@link http://epsg.io }查询) |
| | | * @param [options.style = {}] - Style样式,每种不同类型数据都有不同的样式,具体见各矢量数据的style参数。{@link GraphicType} |
| | | * @param [options.crs] - 原始数据的坐标系,如'EPSG:3857' (可以从 {@link http://epsg.io }查询) |
| | | * @param [options.hasEdit] - 当需要编辑时可以传true值,指定为Entity类型 |
| | | * @returns Graphic构造参数(用于创建{@link BaseGraphic}) |
| | | */ |
| | | function featureToGraphic(feature: any, options?: { |
| | | type?: GraphicType; |
| | | crs?: string; |
| | | style?: any; |
| | | crs?: string; |
| | | hasEdit?: boolean; |
| | | }): any; |
| | | /** |
| | |
| | | * @param altitude - 高度值 |
| | | * @returns 地图层级,通常为 0-21 |
| | | */ |
| | | function heightToZoom(altitude: number): Int; |
| | | function heightToZoom(altitude: number): number; |
| | | /** |
| | | * 根据图层的config的配置信息,自动加上代理等配置返回Resource对象 |
| | | * @param config - 图层的配置信息 |