@JsType(isNative=true, namespace="Cesium", name="GroundPolylinePrimitive") public class GroundPolylinePrimitive extends Object
Scene
.
Only to be used with GeometryInstances containing GroundPolylineGeometry
.Modifier and Type | Field and Description |
---|---|
Appearance |
appearance
The Appearance used to shade this primitive.
|
ClassificationType |
classificationType
Determines whether terrain, 3D Tiles or both will be classified.
|
boolean |
debugShowBoundingVolume
This property is for debugging only; it is not for production use nor is it optimized.
|
boolean |
show
Determines if the primitive will be shown.
|
Constructor and Description |
---|
GroundPolylinePrimitive() |
GroundPolylinePrimitive(GroundPolylinePrimitiveOptions options) |
Modifier and Type | Method and Description |
---|---|
boolean |
allowPicking()
When true, each geometry instance will only be pickable with
Scene.pick(Cartesian2) . |
boolean |
asynchronous()
Determines if the geometry instances will be created and batched on a web worker.
|
boolean |
debugShowShadowVolume()
This property is for debugging only; it is not for production use nor is it optimized.
|
void |
destroy()
Destroys the WebGL resources held by this object.
|
GeometryInstance[] |
geometryInstances()
The geometry instances rendered with this primitive.
|
JsObject |
getGeometryInstanceAttributes(JsObject id)
Returns the modifiable per-instance attributes for a GeometryInstance.
|
static Promise<Void,Void> |
initializeTerrainHeights()
Initializes the minimum and maximum terrain heights.
|
boolean |
interleave()
Determines if geometry vertex attributes are interleaved, which can slightly improve rendering performance.
|
boolean |
isDestroyed()
Returns true if this object was destroyed; otherwise, false.
|
static boolean |
isSupported(Scene scene)
Checks if the given Scene supports GroundPolylinePrimitives.
|
boolean |
ready()
Determines if the primitive is complete and ready to render.
|
Promise<GroundPolylinePrimitive,Void> |
readyPromise()
Gets a promise that resolves when the primitive is ready to render.
|
boolean |
releaseGeometryInstances()
When true, the primitive does not keep a reference to the input geometryInstances to save memory.
|
void |
update()
Called when Viewer or CesiumWidget render the scene to get the draw commands needed to render this primitive.
|
@JsProperty public Appearance appearance
PolylineColorAppearance
allow giving each instance unique properties.
Default: undefined@JsProperty public ClassificationType classificationType
ClassificationType.BOTH()
@JsProperty public boolean debugShowBoundingVolume
@JsProperty public boolean show
@JsConstructor public GroundPolylinePrimitive()
@JsConstructor public GroundPolylinePrimitive(GroundPolylinePrimitiveOptions options)
@JsProperty(name="allowPicking") public boolean allowPicking()
Scene.pick(Cartesian2)
.
When false, GPU memory is saved.
Default: true@JsProperty(name="asynchronous") public boolean asynchronous()
@JsProperty(name="debugShowShadowVolume") public boolean debugShowShadowVolume()
@JsProperty(name="geometryInstances") public GeometryInstance[] geometryInstances()
@JsProperty(name="interleave") public boolean interleave()
@JsProperty(name="ready") public boolean ready()
update()
is called.@JsProperty(name="readyPromise") public Promise<GroundPolylinePrimitive,Void> readyPromise()
@JsProperty(name="releaseGeometryInstances") public boolean releaseGeometryInstances()
@JsMethod public static Promise<Void,Void> initializeTerrainHeights()
@JsMethod public static boolean isSupported(Scene scene)
scene
- The current scene.@JsMethod public void destroy()
@JsMethod public JsObject getGeometryInstanceAttributes(JsObject id)
id
- The id of the GeometryInstance.JsObject attributes = primitive.getGeometryInstanceAttributes('an id');
attributes.setProperty("color", Cesium.ColorGeometryInstanceAttribute.toValue(Cesium.Color.AQUA));
attributes.setProperty("show", Cesium.ShowGeometryInstanceAttribute.toValue(true));
@JsMethod public boolean isDestroyed()
@JsMethod public void update()
Copyright © 2019. All rights reserved.