new ViewDome(scene)
Openness analysis category
| Name | Type | Description |
|---|---|---|
scene |
Object |
Scenarios for openness analysis. |
Throws:
-
We need a scene.
- Type
- DeveloperError
Members
-
distancenumber
-
Get or set the distance.
- Default Value: undefined
domeTypenumber
Obtain and set the display type of openness analysis results.
- Default Value: ViewDomeType.ALLDOME
endAnglenumber
Obtain or set the termination angle for openness analysis.
- Default Value: 360.0
hiddenAreaColorColor
Get or set the color of the hidden part.
- Default Value: SuperMap3D.Color(1.0,0.0,0.0,0.5)
isClosedboolean
Get or set whether a sealing interface is provided at the notch, true for sealing, false for not sealing, default to false. This parameter setting is invalid when closing a hemisphere 360 degrees.
- Default Value: false
startAnglenumber
Obtain or set the starting angle for openness analysis.
- Default Value: 0.0
viewPositionArray
Get or set the viewpoint position (angle).
- Default Value: [0.0,0.0,0.0]
visibleAreaColorColor
Get or set the color of the visible part.
- Default Value: SuperMap3D.Color(0.0,1.0,0.0,0.5)
Methods
-
build()
-
Perform openness analysis.
-
clear()
-
Clear analysis.
-
destroy()
-
Destroy the resources held by the openness analysis object.
-
getViewDomeRatio(viewDomeType){Promise}
-
Obtain the proportion of openness analysis. This feature relies on openness analysis and requires ViewDome. build() to execute and obtain visual analysis results before it can be executed correctly
Name Type Description viewDomeTypeViewDomeType Openness analysis type, if the parameter is VISIBLEDOME, returns the proportion of the visible part of the sky in the sky, and if the parameter is HIDDENDOME, returns the proportion of the invisible part of the sky in the sky.
Returns:
Type Description Promise Return promise, obtain openness analysis upon successful analysis, return undefined upon failure Example
let viewDome = new SuperMap3D.ViewDome(scene); viewDome.viewPosition = new SuperMap3D.Cartesian3(X, X, X); viewDome.build(); // Perform openness analysis first // After obtaining the visualization result of openness analysis, call the API to get the openness ratio let promise = viewDome.getViewDomeRatio(SuperMap3D.ViewDomeType.VISIBLEDOME); prmomise.then((resultRatio) => { console.log(resultRatio); });