用于创建二维平面圆形或扇形的基础几何体。
可以使用
Primitive
也可以使用 GroundPrimitive
两种渲染方式。
Name | Type | Default | Description |
---|---|---|---|
options.center |
Cartesian3 | 圆在固定框架中的中心点。 | |
options.radius |
Number | 以米为单位的半径。 | |
options.ellipsoid |
Ellipsoid |
Ellipsoid.WGS84
|
optional 圆所在的椭球体。 |
options.height |
Number |
0.0
|
optional 圆与椭球面之间的距离(以米为单位)。 |
options.granularity |
Number |
0.02
|
optional 圆上点之间的角距离,以弧度为单位。 |
options.vertexFormat |
VertexFormat |
VertexFormat.DEFAULT
|
optional 要计算的顶点属性。 |
options.extrudedHeight |
Number |
0.0
|
optional 圆的拉伸面和椭球面之间的距离(以米为单位)。 |
options.stRotation |
Number |
0.0
|
optional 纹理坐标的旋转,以弧度为单位。正向旋转是逆时针方向。 |
Throws:
-
DeveloperError : 半径必须大于零。
-
DeveloperError : 粒度必须大于零。
Example:
// Create a circle.
var circle = new SuperMap3D.CircleGeometry({
center : SuperMap3D.Cartesian3.fromDegrees(-75.59777, 40.03883),
radius : 100000.0
});
var geometry = SuperMap3D.CircleGeometry.createGeometry(circle);
See:
Members
-
用于将对象打包到数组中的元素个数。
Methods
-
staticSuperMap3D.CircleGeometry.createGeometry(circleGeometry) → Geometry|undefined
-
计算椭球体表面圆形的几何结构(包括顶点、索引及包围球)的算法实现。
Name Type Description circleGeometry
CircleGeometry 圆的描述。 Returns:
计算的顶点和索引。 -
将提供的实例存储到提供的数组中。
Name Type Default Description value
CircleGeometry 要打包的值。 array
Array.<Number> 要打包的数组。 startingIndex
Number 0
optional 开始打包元素的数组索引。 Returns:
装入的数组。 -
staticSuperMap3D.CircleGeometry.unpack(array, startingIndex, result) → CircleGeometry
-
从打包数组中检索实例。
Name Type Default Description array
Array.<Number> 打包的数组。 startingIndex
Number 0
optional 要解包的元素的起始索引。 result
CircleGeometry optional 存储结果的对象。 Returns:
修改后的结果参数或新的 CircleGeometry 实例(如果未提供)。