修改全局高程
This commit is contained in:
@ -76,7 +76,7 @@ function accordingToCameraHeight() {
|
||||
}
|
||||
|
||||
function startDraw(sdk, showData) {
|
||||
if(!sdk || !sdk.viewer) {
|
||||
if (!sdk || !sdk.viewer) {
|
||||
return
|
||||
}
|
||||
if (showData) {
|
||||
@ -129,8 +129,28 @@ function reset() {
|
||||
supplementaryContourShow = false
|
||||
supplementaryContourWidth = 1.0
|
||||
supplementaryContourColor = '#d084d1'
|
||||
|
||||
|
||||
}
|
||||
function setVal(data) {
|
||||
secondaryLinesCount = data['secondaryLinesCount']
|
||||
// show = true
|
||||
equalHeightDistance = data['equalHeightDistance']
|
||||
activeColor = rgbaFromObject(data['activeColor'])
|
||||
indexContourShow = data['indexContourShow']
|
||||
indexContourWidth = data['indexContourWidth']
|
||||
indexContourColor = rgbaFromObject(data['indexContourColor'])
|
||||
intermediateContourShow = data['intermediateContourShow']
|
||||
intermediateContourWidth = data['intermediateContourWidth']
|
||||
intermediateContourColor = rgbaFromObject(data['intermediateContourColor'])
|
||||
halfIntervalContourShow = data['halfIntervalContourShow']
|
||||
halfIntervalContourWidth = data['halfIntervalContourWidth']
|
||||
halfIntervalContourColor = rgbaFromObject(data['halfIntervalContourColor'])
|
||||
supplementaryContourShow = data['supplementaryContourShow']
|
||||
supplementaryContourWidth = data['supplementaryContourWidth']
|
||||
supplementaryContourColor = rgbaFromObject(data['supplementaryContourColor'])
|
||||
}
|
||||
function rgbaFromObject(colorObj) {
|
||||
const { red, green, blue, alpha = 1 } = colorObj;
|
||||
return `rgba(${red * 255}, ${green * 255}, ${blue * 255}, ${alpha})`;
|
||||
}
|
||||
async function dialog(sdk) {
|
||||
_sdk = sdk
|
||||
@ -716,4 +736,4 @@ czm_material czm_getMaterial(czm_materialInput materialInput)
|
||||
});
|
||||
}
|
||||
|
||||
export { dialog, startDraw, reset }
|
||||
export { dialog, startDraw, reset, setVal }
|
||||
|
||||
@ -71,7 +71,7 @@ import {
|
||||
} from '../Global/MultiViewportMode'
|
||||
import { MouseCoordinate } from '../Global/MouseCoordinate'
|
||||
import { MouseRightMenu } from '../Global/mouseRightMenu'
|
||||
import { dialog as ContourDialog, startDraw as ContourStartDraw, reset as ContourReset } from '../Global/Contour'
|
||||
import { dialog as ContourDialog, startDraw as ContourStartDraw, reset as ContourReset, setVal as ContourSetVal } from '../Global/Contour'
|
||||
import { on as SplitScreenOn, off as SplitScreenOff, setActiveId as SplitScreenSetActiveId, getSdk } from '../Global/SplitScreen'
|
||||
import LocateCurrent from '../Obj/Base/LocateCurrent'
|
||||
|
||||
@ -352,7 +352,8 @@ if (!window.YJ) {
|
||||
},
|
||||
Contour: ContourDialog,
|
||||
ContourStartDraw,
|
||||
ContourReset
|
||||
ContourReset,
|
||||
ContourSetVal
|
||||
}, //测量
|
||||
Measure: {
|
||||
GetMeasureStatus: () => {
|
||||
|
||||
Reference in New Issue
Block a user