new Cesium.RectangleGraphics(options)

Describes graphics for a Rectangle. 矩形符合地球的曲面,可以放置在表面或 在高度上,可以选择挤出一个卷.
Name Type Description
options RectangleGraphics.ConstructorOptions optional 描述初始化选项的对象
Demo:
See:

Members

classificationType : Property|undefined

Gets or sets the ClassificationType Property specifying whether this rectangle will classify terrain, 3D Tiles, or both when on the ground.
Default Value: ClassificationType.BOTH

coordinates : Property|undefined

Gets or sets the Property specifying the Rectangle.

readonly definitionChanged : Event

当财产或次级财产被改变或修改时,获取该事件.

distanceDisplayCondition : Property|undefined

Gets or sets the DistanceDisplayCondition Property specifying at what distance from the camera that this rectangle will be displayed.

extrudedHeight : Property|undefined

获取或设置指定矩形挤压高度的数值属性. 设置此属性将生成从高度开始到在此高度结束的体积 .

extrudedHeightReference : Property|undefined

Gets or sets the Property specifying the extruded HeightReference.
Default Value: HeightReference.NONE

fill : Property|undefined

获取或设置布尔属性,指定矩形是否由所提供的材料填充.
Default Value: true

granularity : Property|undefined

获取或设置指定矩形各点之间的角距离的数值属性.
Default Value: {CesiumMath.RADIANS_PER_DEGREE}

height : Property|undefined

获取或设置指定矩形高度的数值属性.
Default Value: 0.0

heightReference : Property|undefined

Gets or sets the Property specifying the HeightReference.
Default Value: HeightReference.NONE

material : MaterialProperty

获取或设置属性,指定用于填充矩形的材料.
Default Value: Color.WHITE

outline : Property|undefined

获取或设置属性,指定矩形是否被勾勒 .
Default Value: false

outlineColor : Property|undefined

获取或设置指定大纲的 Color 的属性 .
Default Value: Color.BLACK

outlineWidth : Property|undefined

获取或设置指定大纲宽度的数字属性.

Note: This property will be ignored on all major browsers on Windows platforms. For details, see (@link https://github.com/CesiumGS/cesium/issues/40}.

Default Value: 1.0

rotation : Property|undefined

获取或设置指定矩形顺时针自北向旋转的数值属性.
Default Value: 0

shadows : Property|undefined

获取或设置 enum 属性,指定是否为矩形 投影或接收来自光源的阴影.
Default Value: ShadowMode.DISABLED

show : Property|undefined

获取或设置指定矩形可见度的布尔属性.
Default Value: true

stRotation : Property|undefined

获取或设置指定矩形纹理逆时针自北旋转的数值属性.
Default Value: 0

zIndex : ConstantProperty|undefined

获取或设置指定矩形顺序的 zIndex 属性。 只有当矩形是恒定的,并且既不指定高度,也不指定外观高度时,才产生效果.
Default Value: 0

Methods

clone(result)RectangleGraphics

重复这个例子.
Name Type Description
result RectangleGraphics optional 存储结果的对象 .
Returns:
未提供修改的结果参数或新实例 .

merge(source)

指定该对象上每个未指定属性的值 - 提供源对象上的同一财产.
Name Type Description
source RectangleGraphics 要合并成此天体的对象.

Type Definitions

Cesium.RectangleGraphics.ConstructorOptions

矩形图形构建器的初始化选项
Properties:
Name Type Attributes Default Description
show Property | boolean <optional>
true A boolean Property specifying the visibility of the rectangle.
coordinates Property | Rectangle <optional>
The Property specifying the Rectangle.
height Property | number <optional>
0 A numeric Property specifying the altitude of the rectangle relative to the ellipsoid surface.
heightReference Property | HeightReference <optional>
HeightReference.NONE A Property specifying what the height is relative to.
extrudedHeight Property | number <optional>
指定矩形外凸面相对于椭圆表面高度的数值属性.
extrudedHeightReference Property | HeightReference <optional>
HeightReference.NONE A Property specifying what the extrudedHeight is relative to.
rotation Property | number <optional>
0.0 一个数字属性,指定矩形顺时针从北向旋转.
stRotation Property | number <optional>
0.0 指定矩形纹理逆时针自北旋转的数值属性.
granularity Property | number <optional>
Cesium.Math.RADIANS_PER_DEGREE A numeric Property specifying the angular distance between points on the rectangle.
fill Property | boolean <optional>
true A boolean Property specifying whether the rectangle is filled with the provided material.
material MaterialProperty | Color <optional>
Color.WHITE A Property specifying the material used to fill the rectangle.
outline Property | boolean <optional>
false A boolean Property specifying whether the rectangle is outlined.
outlineColor Property | Color <optional>
Color.BLACK A Property specifying the Color of the outline.
outlineWidth Property | number <optional>
1.0 指定大纲宽度的数值属性.
shadows Property | ShadowMode <optional>
ShadowMode.DISABLED An enum Property specifying whether the rectangle casts or receives shadows from light sources.
distanceDisplayCondition Property | DistanceDisplayCondition <optional>
指定此矩形显示距离相机的属性 .
classificationType Property | ClassificationType <optional>
ClassificationType.BOTH An enum Property specifying whether this rectangle will classify terrain, 3D Tiles, or both when on the ground.
zIndex Property | number <optional>
0 A Property specifying the zIndex used for ordering ground geometry. Only has an effect if the rectangle is constant and neither height or extrudedHeight are specified.
Need help? The fastest way to get answers is from the community and team on the Cesium Forum.