PointPrimitive

external class PointPrimitive(source)
A point is created and its initial properties are set by calling [PointPrimitiveCollection.add]. Do not call the constructor directly.
A graphical point positioned in the 3D scene, that is created and rendered using a [PointPrimitiveCollection].

See also

Properties

Link copied to clipboard

Gets or sets the inner color of the point. The red, green, blue, and alpha values are indicated by value's red, green, blue, and alpha properties as shown in Example 1. These components range from 0.0 (no intensity) to 1.0 (full intensity).

Link copied to clipboard

Gets or sets the distance from the camera at which to disable the depth test to, for example, prevent clipping against terrain. When set to zero, the depth test is always applied. When set to Number.POSITIVE_INFINITY, the depth test is never applied.

Link copied to clipboard

Gets or sets the condition specifying at what distance from the camera that this point will be displayed.

Link copied to clipboard
var id: Any

Gets or sets the user-defined value returned when the point is picked.

Link copied to clipboard

Gets or sets the outline color of the point.

Link copied to clipboard

Gets or sets the outline width in pixels. This width adds to pixelSize, increasing the total size of the point.

Link copied to clipboard

Gets or sets the inner size of the point in pixels.

Link copied to clipboard

Gets or sets the Cartesian position of this point.

Link copied to clipboard

Gets or sets near and far scaling properties of a point based on the point's distance from the camera. A point's scale will interpolate between the NearFarScalar.nearValue and NearFarScalar.farValue while the camera distance falls within the lower and upper bounds of the specified NearFarScalar.near and NearFarScalar.far. Outside of these ranges the point's scale remains clamped to the nearest bound. This scale multiplies the pixelSize and outlineWidth to affect the total size of the point. If undefined, scaleByDistance will be disabled.

Link copied to clipboard

Determines if this point will be shown. Use this to hide or show a point, instead of removing it and re-adding it to the collection.

Link copied to clipboard

The SplitDirection to apply to this point.

Link copied to clipboard

Gets or sets near and far translucency properties of a point based on the point's distance from the camera. A point's translucency will interpolate between the NearFarScalar.nearValue and NearFarScalar.farValue while the camera distance falls within the lower and upper bounds of the specified NearFarScalar.near and NearFarScalar.far. Outside of these ranges the point's translucency remains clamped to the nearest bound. If undefined, translucencyByDistance will be disabled.

Functions

Link copied to clipboard
fun computeScreenSpacePosition(scene: Scene, result: Cartesian2? = definedExternally): Cartesian2

Computes the screen-space position of the point's origin. The screen space origin is the top, left corner of the canvas; x increases from left to right, and y increases from top to bottom.