走廊的描述。走廊幾何圖形可以用
new CorridorGeometry(options)
Primitive
和GroundPrimitive
渲染。
Parameters:
options
(Object)
Name | Description |
---|---|
options.positions
Array.<Cartesian3>
|
定義道路中心的位置數組。 |
options.width
Number
|
走廊邊緣之間的距離,單位為米。 |
options.ellipsoid
Ellipsoid
default Ellipsoid.WGS84
|
用作參考的橢球體。 |
options.granularity
Number
default BMMath.RADIANS_PER_DEGREE
|
每一緯度和經度之間的距離,以弧度表示。確定緩沖區中的位置數。 |
options.height
Number
default 0
|
橢球面與位置之間的距離,單位為米。 |
options.extrudedHeight
Number
|
橢球面與擠壓面之間的距離,單位為米。 |
options.vertexFormat
VertexFormat
default VertexFormat.DEFAULT
|
要計算的頂點屬性。 |
options.cornerType
CornerType
default CornerType.ROUNDED
|
確定角的樣式。 |
Example
var corridor = new bmgl.CorridorGeometry({
vertexFormat : bmgl.VertexFormat.POSITION_ONLY,
positions : bmgl.Cartesian3.fromDegreesArray([-72.0, 40.0, -70.0, 35.0]),
width : 100000
});
- CorridorGeometry.createGeometry
- Packable
See:
Members
packedLength : Number
用于將對象打包到數組中的元素數。
Methods
(static) computeRectangle(options, result) → {Rectangle}
根據提供的選項計算邊界矩形
Parameters:
options
(Object)
Name | Description |
---|---|
options.positions
Array.<Cartesian3>
|
定義道路中心的位置數組。 |
options.width
Number
|
走廊邊緣之間的距離,單位為米。 |
options.ellipsoid
Ellipsoid
default Ellipsoid.WGS84
|
用作參考的橢球體。 |
options.cornerType
CornerType
default CornerType.ROUNDED
|
確定角的樣式。 |
計算道路的幾何表示,包括其頂點、索引和邊界球。
Parameters:
將提供的實例存儲到提供的數組中。
Parameters:
array
(Array.<Number>)
要打包的數組。
startingIndex
(Number)
(default 0
)
數組中開始打包元素的索引。
從壓縮數組中檢索實例。
Parameters:
array
(Array.<Number>)
壓縮數組。
startingIndex
(Number)
(default 0
)
要解包的元素的起始索引。