Global

Members

animationAdded :Event

The event fired when an animation is added to the collection. This can be used, for example, to keep a UI in sync.
Type:
Default Value:
  • new Event()
Source:
Example
model.activeAnimations.animationAdded.addEventListener(function(model, animation) {
  console.log('Animation added: ' + animation.name);
});

animationRemoved :Event

The event fired when an animation is removed from the collection. This can be used, for example, to keep a UI in sync.
Type:
Default Value:
  • new Event()
Source:
Example
model.activeAnimations.animationRemoved.addEventListener(function(model, animation) {
  console.log('Animation removed: ' + animation.name);
});

boundingVolume :Object

The bounding volume of the geometry in world space. This is used for culling and frustum selection.

For best rendering performance, use the tightest possible bounding volume. Although undefined is allowed, always try to provide a bounding volume to allow the tightest possible near and far planes to be computed for the scene, and minimize the number of frustums needed.

Type:
  • Object
Default Value:
  • undefined
Source:
See:
  • DrawCommand#debugShowBoundingVolume

castShadows :Boolean

Whether this command should cast shadows when shadowing is enabled.
Type:
  • Boolean
Default Value:
  • false
Source:

clockTrackedDataSource :DataSource

Gets or sets the data source to track with the viewer's clock.
Type:
Source:

count :Number

The number of vertices to draw in the vertex array.
Type:
  • Number
Default Value:
  • undefined
Source:

cull :Boolean

When true, the renderer frustum and horizon culls the command based on its DrawCommand#boundingVolume. If the command was already culled, set this to false for a performance improvement.
Type:
  • Boolean
Default Value:
  • true
Source:

czm_currentFrustum

An automatic GLSL uniform containing the near distance (x) and the far distance (y) of the frustum defined by the camera. This is the individual frustum used for multi-frustum rendering.
Source:
See:
Example
// GLSL declaration
uniform vec2 czm_currentFrustum;

// Example
float frustumLength = czm_currentFrustum.y - czm_currentFrustum.x;

czm_encodedCameraPositionMCHigh

An automatic GLSL uniform representing the high bits of the camera position in model coordinates. This is used for GPU RTE to eliminate jittering artifacts when rendering as described in Precisions, Precisions.
Source:
See:
Example
// GLSL declaration
uniform vec3 czm_encodedCameraPositionMCHigh;

czm_encodedCameraPositionMCLow

An automatic GLSL uniform representing the low bits of the camera position in model coordinates. This is used for GPU RTE to eliminate jittering artifacts when rendering as described in Precisions, Precisions.
Source:
See:
Example
// GLSL declaration
uniform vec3 czm_encodedCameraPositionMCLow;

czm_entireFrustum

An automatic GLSL uniform containing the near distance (x) and the far distance (y) of the frustum defined by the camera. This is the largest possible frustum, not an individual frustum used for multi-frustum rendering.
Source:
See:
Example
// GLSL declaration
uniform vec2 czm_entireFrustum;

// Example
float frustumLength = czm_entireFrustum.y - czm_entireFrustum.x;

czm_eyeHeight2D

An automatic GLSL uniform containing height (x) and height squared (y) of the eye (camera) in the 2D scene in meters.
Source:
See:

czm_fogDensity

An automatic GLSL uniform scalar used to mix a color with the fog color based on the distance to the camera.
Source:
See:
  • czm_fog

czm_frameNumber

An automatic GLSL uniform representing the frame number. This uniform is automatically incremented every frame.
Source:
Example
// GLSL declaration
uniform float czm_frameNumber;

czm_frustumPlanes

The distances to the frustum planes. The top, bottom, left and right distances are the x, y, z, and w components, respectively.
Source:

czm_infiniteProjection

An automatic GLSL uniform representing a 4x4 projection transformation matrix with the far plane at infinity, that transforms eye coordinates to clip coordinates. Clip coordinates is the coordinate system for a vertex shader's gl_Position output. An infinite far plane is used in algorithms like shadow volumes and GPU ray casting with proxy geometry to ensure that triangles are not clipped by the far plane.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_infiniteProjection;

// Example
gl_Position = czm_infiniteProjection * eyePosition;

czm_inverseModel

An automatic GLSL uniform representing a 4x4 model transformation matrix that transforms world coordinates to model coordinates.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_inverseModel;

// Example
vec4 modelPosition = czm_inverseModel * worldPosition;

czm_inverseModelView

An automatic GLSL uniform representing a 4x4 transformation matrix that transforms from eye coordinates to model coordinates.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_inverseModelView;

// Example
vec4 modelPosition = czm_inverseModelView * eyePosition;

czm_inverseModelView3D

An automatic GLSL uniform representing a 4x4 transformation matrix that transforms from eye coordinates to 3D model coordinates. In 3D mode, this is identical to czm_inverseModelView, but in 2D and Columbus View it represents the inverse model-view matrix as if the camera were at an equivalent location in 3D mode. This is useful for lighting 2D and Columbus View in the same way that 3D is lit.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_inverseModelView3D;

// Example
vec4 modelPosition = czm_inverseModelView3D * eyePosition;

czm_inverseModelViewProjection

An automatic GLSL uniform representing a 4x4 inverse model-view-projection transformation matrix that transforms clip coordinates to model coordinates. Clip coordinates is the coordinate system for a vertex shader's gl_Position output.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_inverseModelViewProjection;

// Example
vec4 modelPosition = czm_inverseModelViewProjection * clipPosition;

czm_inverseNormal

An automatic GLSL uniform representing a 3x3 normal transformation matrix that transforms normal vectors in eye coordinates to model coordinates. This is the opposite of the transform provided by czm_normal.
Source:
See:
Example
// GLSL declaration
uniform mat3 czm_inverseNormal;

// Example
vec3 normalMC = czm_inverseNormal * normalEC;

czm_inverseNormal3D

An automatic GLSL uniform representing a 3x3 normal transformation matrix that transforms normal vectors in eye coordinates to 3D model coordinates. This is the opposite of the transform provided by czm_normal. In 3D mode, this is identical to czm_inverseNormal, but in 2D and Columbus View it represents the inverse normal transformation matrix as if the camera were at an equivalent location in 3D mode. This is useful for lighting 2D and Columbus View in the same way that 3D is lit.
Source:
See:
Example
// GLSL declaration
uniform mat3 czm_inverseNormal3D;

// Example
vec3 normalMC = czm_inverseNormal3D * normalEC;

czm_inverseProjection

An automatic GLSL uniform representing a 4x4 inverse projection transformation matrix that transforms from clip coordinates to eye coordinates. Clip coordinates is the coordinate system for a vertex shader's gl_Position output.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_inverseProjection;

// Example
vec4 eyePosition = czm_inverseProjection * clipPosition;

czm_inverseView

An automatic GLSL uniform representing a 4x4 transformation matrix that transforms from eye coordinates to world coordinates.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_inverseView;

// Example
vec4 worldPosition = czm_inverseView * eyePosition;

czm_inverseView3D

An automatic GLSL uniform representing a 4x4 transformation matrix that transforms from 3D eye coordinates to world coordinates. In 3D mode, this is identical to czm_inverseView, but in 2D and Columbus View it represents the inverse view matrix as if the camera were at an equivalent location in 3D mode. This is useful for lighting 2D and Columbus View in the same way that 3D is lit.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_inverseView3D;

// Example
vec4 worldPosition = czm_inverseView3D * eyePosition;

czm_inverseViewProjection

An automatic GLSL uniform representing a 4x4 view-projection transformation matrix that transforms clip coordinates to world coordinates. Clip coordinates is the coordinate system for a vertex shader's gl_Position output.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_inverseViewProjection;

// Example
vec4 worldPosition = czm_inverseViewProjection * clipPosition;

czm_inverseViewRotation

An automatic GLSL uniform representing a 3x3 rotation matrix that transforms vectors from eye coordinates to world coordinates.
Source:
See:
Example
// GLSL declaration
uniform mat3 czm_inverseViewRotation;

// Example
vec4 worldVector = czm_inverseViewRotation * eyeVector;

czm_inverseViewRotation3D

An automatic GLSL uniform representing a 3x3 rotation matrix that transforms vectors from 3D eye coordinates to world coordinates. In 3D mode, this is identical to czm_inverseViewRotation, but in 2D and Columbus View it represents the inverse view matrix as if the camera were at an equivalent location in 3D mode. This is useful for lighting 2D and Columbus View in the same way that 3D is lit.
Source:
See:
Example
// GLSL declaration
uniform mat3 czm_inverseViewRotation3D;

// Example
vec4 worldVector = czm_inverseViewRotation3D * eyeVector;

czm_model

An automatic GLSL uniform representing a 4x4 model transformation matrix that transforms model coordinates to world coordinates.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_model;

// Example
vec4 worldPosition = czm_model * modelPosition;

czm_modelView

An automatic GLSL uniform representing a 4x4 model-view transformation matrix that transforms model coordinates to eye coordinates.

Positions should be transformed to eye coordinates using czm_modelView and normals should be transformed using czm_normal.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_modelView;

// Example
vec4 eyePosition = czm_modelView * modelPosition;

// The above is equivalent to, but more efficient than:
vec4 eyePosition = czm_view * czm_model * modelPosition;

czm_modelView3D

An automatic GLSL uniform representing a 4x4 model-view transformation matrix that transforms 3D model coordinates to eye coordinates. In 3D mode, this is identical to czm_modelView, but in 2D and Columbus View it represents the model-view matrix as if the camera were at an equivalent location in 3D mode. This is useful for lighting 2D and Columbus View in the same way that 3D is lit.

Positions should be transformed to eye coordinates using czm_modelView3D and normals should be transformed using czm_normal3D.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_modelView3D;

// Example
vec4 eyePosition = czm_modelView3D * modelPosition;

// The above is equivalent to, but more efficient than:
vec4 eyePosition = czm_view3D * czm_model * modelPosition;

czm_modelViewInfiniteProjection

An automatic GLSL uniform representing a 4x4 model-view-projection transformation matrix that transforms model coordinates to clip coordinates. Clip coordinates is the coordinate system for a vertex shader's gl_Position output. The projection matrix places the far plane at infinity. This is useful in algorithms like shadow volumes and GPU ray casting with proxy geometry to ensure that triangles are not clipped by the far plane.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_modelViewInfiniteProjection;

// Example
vec4 gl_Position = czm_modelViewInfiniteProjection * modelPosition;

// The above is equivalent to, but more efficient than:
gl_Position = czm_infiniteProjection * czm_view * czm_model * modelPosition;

czm_modelViewProjection

An automatic GLSL uniform representing a 4x4 model-view-projection transformation matrix that transforms model coordinates to clip coordinates. Clip coordinates is the coordinate system for a vertex shader's gl_Position output.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_modelViewProjection;

// Example
vec4 gl_Position = czm_modelViewProjection * modelPosition;

// The above is equivalent to, but more efficient than:
gl_Position = czm_projection * czm_view * czm_model * modelPosition;

czm_modelViewProjectionRelativeToEye

An automatic GLSL uniform representing a 4x4 model-view-projection transformation matrix that transforms model coordinates, relative to the eye, to clip coordinates. Clip coordinates is the coordinate system for a vertex shader's gl_Position output. This is used in conjunction with czm_translateRelativeToEye.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_modelViewProjectionRelativeToEye;

// Example
attribute vec3 positionHigh;
attribute vec3 positionLow;

void main()
{
  vec4 p = czm_translateRelativeToEye(positionHigh, positionLow);
  gl_Position = czm_modelViewProjectionRelativeToEye * p;
}

czm_modelViewRelativeToEye

An automatic GLSL uniform representing a 4x4 model-view transformation matrix that transforms model coordinates, relative to the eye, to eye coordinates. This is used in conjunction with czm_translateRelativeToEye.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_modelViewRelativeToEye;

// Example
attribute vec3 positionHigh;
attribute vec3 positionLow;

void main()
{
  vec4 p = czm_translateRelativeToEye(positionHigh, positionLow);
  gl_Position = czm_projection * (czm_modelViewRelativeToEye * p);
}

czm_moonDirectionEC

An automatic GLSL uniform representing the normalized direction to the moon in eye coordinates. This is commonly used for directional lighting computations.
Source:
See:
Example
// GLSL declaration
uniform vec3 czm_moonDirectionEC;

// Example
float diffuse = max(dot(czm_moonDirectionEC, normalEC), 0.0);

czm_morphTime

An automatic GLSL uniform representing the current morph transition time between 2D/Columbus View and 3D, with 0.0 being 2D or Columbus View and 1.0 being 3D.
Source:
Example
// GLSL declaration
uniform float czm_morphTime;

// Example
vec4 p = czm_columbusViewMorph(position2D, position3D, czm_morphTime);

czm_normal

An automatic GLSL uniform representing a 3x3 normal transformation matrix that transforms normal vectors in model coordinates to eye coordinates.

Positions should be transformed to eye coordinates using czm_modelView and normals should be transformed using czm_normal.
Source:
See:
Example
// GLSL declaration
uniform mat3 czm_normal;

// Example
vec3 eyeNormal = czm_normal * normal;

czm_normal3D

An automatic GLSL uniform representing a 3x3 normal transformation matrix that transforms normal vectors in 3D model coordinates to eye coordinates. In 3D mode, this is identical to czm_normal, but in 2D and Columbus View it represents the normal transformation matrix as if the camera were at an equivalent location in 3D mode. This is useful for lighting 2D and Columbus View in the same way that 3D is lit.

Positions should be transformed to eye coordinates using czm_modelView3D and normals should be transformed using czm_normal3D.
Source:
See:
Example
// GLSL declaration
uniform mat3 czm_normal3D;

// Example
vec3 eyeNormal = czm_normal3D * normal;

czm_pass

An automatic GLSL uniform representing the current rendering pass.
Source:
Example
// GLSL declaration
uniform float czm_pass;

// Example
if ((czm_pass == czm_passTranslucent) && isOpaque())
{
    gl_Position *= 0.0; // Cull opaque geometry in the translucent pass
}

czm_projection

An automatic GLSL uniform representing a 4x4 projection transformation matrix that transforms eye coordinates to clip coordinates. Clip coordinates is the coordinate system for a vertex shader's gl_Position output.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_projection;

// Example
gl_Position = czm_projection * eyePosition;

czm_resolutionScale

An automatic GLSL uniform representing the ratio of canvas coordinate space to canvas pixel space.
Source:
Example
uniform float czm_resolutionScale;

czm_sceneMode

An automatic GLSL uniform representing the current SceneMode, expressed as a float.
Source:
See:
  • czm_sceneMode2D
  • czm_sceneModeColumbusView
  • czm_sceneMode3D
  • czm_sceneModeMorphing
Example
// GLSL declaration
uniform float czm_sceneMode;

// Example
if (czm_sceneMode == czm_sceneMode2D)
{
    eyeHeightSq = czm_eyeHeight2D.y;
}

czm_sunDirectionEC

An automatic GLSL uniform representing the normalized direction to the sun in eye coordinates. This is commonly used for directional lighting computations.
Source:
See:
Example
// GLSL declaration
uniform vec3 czm_sunDirectionEC;

// Example
float diffuse = max(dot(czm_sunDirectionEC, normalEC), 0.0);

czm_sunDirectionWC

An automatic GLSL uniform representing the normalized direction to the sun in world coordinates. This is commonly used for directional lighting computations.
Source:
See:
Example
// GLSL declaration
uniform vec3 czm_sunDirectionWC;

czm_sunPositionColumbusView

An automatic GLSL uniform representing the sun position in Columbus view world coordinates.
Source:
See:
Example
// GLSL declaration
uniform vec3 czm_sunPositionColumbusView;

czm_sunPositionWC

An automatic GLSL uniform representing the sun position in world coordinates.
Source:
See:
Example
// GLSL declaration
uniform vec3 czm_sunPositionWC;

czm_temeToPseudoFixed

An automatic GLSL uniform representing a 3x3 rotation matrix that transforms from True Equator Mean Equinox (TEME) axes to the pseudo-fixed axes at the current scene time.
Source:
See:
Example
// GLSL declaration
uniform mat3 czm_temeToPseudoFixed;

// Example
vec3 pseudoFixed = czm_temeToPseudoFixed * teme;

czm_view

An automatic GLSL uniform representing a 4x4 view transformation matrix that transforms world coordinates to eye coordinates.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_view;

// Example
vec4 eyePosition = czm_view * worldPosition;

czm_view3D

An automatic GLSL uniform representing a 4x4 view transformation matrix that transforms 3D world coordinates to eye coordinates. In 3D mode, this is identical to czm_view, but in 2D and Columbus View it represents the view matrix as if the camera were at an equivalent location in 3D mode. This is useful for lighting 2D and Columbus View in the same way that 3D is lit.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_view3D;

// Example
vec4 eyePosition3D = czm_view3D * worldPosition3D;

czm_viewerPositionWC

An automatic GLSL uniform representing the position of the viewer (camera) in world coordinates.
Source:
Example
// GLSL declaration
uniform vec3 czm_viewerPositionWC;

czm_viewport

An automatic GLSL uniform containing the viewport's x, y, width, and height properties in an vec4's x, y, z, and w components, respectively.
Source:
See:
  • Context#getViewport
Example
// GLSL declaration
uniform vec4 czm_viewport;

// Scale the window coordinate components to [0, 1] by dividing
// by the viewport's width and height.
vec2 v = gl_FragCoord.xy / czm_viewport.zw;

czm_viewportOrthographic

An automatic GLSL uniform representing a 4x4 orthographic projection matrix that transforms window coordinates to clip coordinates. Clip coordinates is the coordinate system for a vertex shader's gl_Position output.

This transform is useful when a vertex shader inputs or manipulates window coordinates as done by BillboardCollection.

Do not confuse czm_viewportTransformation with czm_viewportOrthographic. The former transforms from normalized device coordinates to window coordinates; the later transforms from window coordinates to clip coordinates, and is often used to assign to gl_Position.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_viewportOrthographic;

// Example
gl_Position = czm_viewportOrthographic * vec4(windowPosition, 0.0, 1.0);

czm_viewportTransformation

An automatic GLSL uniform representing a 4x4 transformation matrix that transforms normalized device coordinates to window coordinates. The context's full viewport is used, and the depth range is assumed to be near = 0 and far = 1.

This transform is useful when there is a need to manipulate window coordinates in a vertex shader as done by BillboardCollection. In many cases, this matrix will not be used directly; instead, czm_modelToWindowCoordinates will be used to transform directly from model to window coordinates.

Do not confuse czm_viewportTransformation with czm_viewportOrthographic. The former transforms from normalized device coordinates to window coordinates; the later transforms from window coordinates to clip coordinates, and is often used to assign to gl_Position.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_viewportTransformation;

// Use czm_viewportTransformation as part of the
// transform from model to window coordinates.
vec4 q = czm_modelViewProjection * positionMC;               // model to clip coordinates
q.xyz /= q.w;                                                // clip to normalized device coordinates (ndc)
q.xyz = (czm_viewportTransformation * vec4(q.xyz, 1.0)).xyz; // ndc to window coordinates

czm_viewProjection

An automatic GLSL uniform representing a 4x4 view-projection transformation matrix that transforms world coordinates to clip coordinates. Clip coordinates is the coordinate system for a vertex shader's gl_Position output.
Source:
See:
Example
// GLSL declaration
uniform mat4 czm_viewProjection;

// Example
vec4 gl_Position = czm_viewProjection * czm_model * modelPosition;

// The above is equivalent to, but more efficient than:
gl_Position = czm_projection * czm_view * czm_model * modelPosition;

czm_viewRotation

An automatic GLSL uniform representing a 3x3 view rotation matrix that transforms vectors in world coordinates to eye coordinates.
Source:
See:
Example
// GLSL declaration
uniform mat3 czm_viewRotation;

// Example
vec3 eyeVector = czm_viewRotation * worldVector;

czm_viewRotation3D

An automatic GLSL uniform representing a 3x3 view rotation matrix that transforms vectors in 3D world coordinates to eye coordinates. In 3D mode, this is identical to czm_viewRotation, but in 2D and Columbus View it represents the view matrix as if the camera were at an equivalent location in 3D mode. This is useful for lighting 2D and Columbus View in the same way that 3D is lit.
Source:
See:
Example
// GLSL declaration
uniform mat3 czm_viewRotation3D;

// Example
vec3 eyeVector = czm_viewRotation3D * worldVector;

debugShowBoundingVolume :Boolean

This property is for debugging only; it is not for production use nor is it optimized.

Draws the DrawCommand#boundingVolume for this command, assuming it is a sphere, when the command executes.

Type:
  • Boolean
Default Value:
  • false
Source:
See:
  • DrawCommand#boundingVolume

enablePickFeatures :Boolean

Gets or sets a value indicating whether feature picking is enabled. If true, WebMapServiceImageryProvider#pickFeatures will invoke the GetFeatureInfo service on the WMS server and attempt to interpret the features included in the response. If false, WebMapServiceImageryProvider#pickFeatures will immediately return undefined (indicating no pickable features) without communicating with the server. Set this property to false if you know your data source does not support picking features or if you don't want this provider's features to be pickable.
Type:
  • Boolean
Default Value:
  • true
Source:

executeInClosestFrustum :Boolean

Specifies if this command is only to be executed in the frustum closest to the eye containing the bounding volume. Defaults to false.
Type:
  • Boolean
Default Value:
  • false
Source:

framebuffer :Framebuffer

The framebuffer to draw to.
Type:
Default Value:
  • undefined
Source:

instanceCount :Number

The number of instances to draw.
Type:
  • Number
Default Value:
  • 0
Source:

layers :String

Gets the comma-separated list of layer IDs to show.
Type:
  • String
Source:

modelMatrix :Matrix4

The transformation from the geometry in model space to world space.

When undefined, the geometry is assumed to be defined in world space.

Type:
Default Value:
  • undefined
Source:

offset :Number

The offset to start drawing in the vertex array.
Type:
  • Number
Default Value:
  • 0
Source:

orientedBoundingBox :OrientedBoundingBox

The oriented bounding box of the geometry in world space. If this is defined, it is used instead of DrawCommand#boundingVolume for plane intersection testing.
Type:
Default Value:
  • undefined
Source:
See:
  • DrawCommand#debugShowBoundingVolume

owner :Object

The object who created this command. This is useful for debugging command execution; it allows us to see who created a command when we only have a reference to the command, and can be used to selectively execute commands with Scene#debugCommandFilter.
Type:
  • Object
Default Value:
  • undefined
Source:
See:

pass :Pass

The pass when to render.
Type:
  • Pass
Default Value:
  • undefined
Source:

(readonly) pickFeaturesUrl :String

Gets the URL template to use to use to pick features. If this property is not specified, UrlTemplateImageryProvider#pickFeatures will immediately returned undefined, indicating no features picked. The URL template supports all of the keywords supported by the UrlTemplateImageryProvider#url property, plus the following:
  • {i}: The pixel column (horizontal coordinate) of the picked position, where the Westernmost pixel is 0.
  • {j}: The pixel row (vertical coordinate) of the picked position, where the Northernmost pixel is 0.
  • {reverseI}: The pixel column (horizontal coordinate) of the picked position, where the Easternmost pixel is 0.
  • {reverseJ}: The pixel row (vertical coordinate) of the picked position, where the Southernmost pixel is 0.
  • {longitudeDegrees}: The longitude of the picked position in degrees.
  • {latitudeDegrees}: The latitude of the picked position in degrees.
  • {longitudeProjected}: The longitude of the picked position in the projected coordinates of the tiling scheme.
  • {latitudeProjected}: The latitude of the picked position in the projected coordinates of the tiling scheme.
  • {format}: The format in which to get feature information, as specified in the GetFeatureInfoFormat.
Type:
  • String
Source:

primitiveType :PrimitiveType

The type of geometry in the vertex array.
Type:
  • PrimitiveType
Default Value:
  • PrimitiveType.TRIANGLES
Source:

receiveShadows :Boolean

Whether this command should receive shadows when shadowing is enabled.
Type:
  • Boolean
Default Value:
  • false
Source:

removeOnStop :Boolean

When true, the animation is removed after it stops playing. This is slightly more efficient that not removing it, but if, for example, time is reversed, the animation is not played again.
Type:
  • Boolean
Default Value:
  • false
Source:

renderState :RenderState

The render state.
Type:
  • RenderState
Default Value:
  • undefined
Source:

shaderProgram :ShaderProgram

The shader program to apply.
Type:
Default Value:
  • undefined
Source:

start :Event

The event fired when this animation is started. This can be used, for example, to play a sound or start a particle system, when the animation starts.

This event is fired at the end of the frame after the scene is rendered.

Type:
Default Value:
  • new Event()
Source:
Example
animation.start.addEventListener(function(model, animation) {
  console.log('Animation started: ' + animation.name);
});

stop :Event

The event fired when this animation is stopped. This can be used, for example, to play a sound or start a particle system, when the animation stops.

This event is fired at the end of the frame after the scene is rendered.

Type:
Default Value:
  • new Event()
Source:
Example
animation.stop.addEventListener(function(model, animation) {
  console.log('Animation stopped: ' + animation.name);
});

uniformMap :Object

An object with functions whose names match the uniforms in the shader program and return values to set those uniforms.
Type:
  • Object
Default Value:
  • undefined
Source:

update :Event

The event fired when on each frame when this animation is updated. The current time of the animation, relative to the glTF animation time span, is passed to the event, which allows, for example, starting new animations at a specific time relative to a playing animation.

This event is fired at the end of the frame after the scene is rendered.

Type:
Default Value:
  • new Event()
Source:
Example
animation.update.addEventListener(function(model, animation, time) {
  console.log('Animation updated: ' + animation.name + '. glTF animation time: ' + time);
});

vertexArray :VertexArray

The vertex array.
Type:
  • VertexArray
Default Value:
  • undefined
Source:

Methods

Billboard()

A viewport-aligned image positioned in the 3D scene, that is created and rendered using a BillboardCollection. A billboard is created and its initial properties are set by calling BillboardCollection#add.


Example billboards
Source:
See:
Throws:
  • scaleByDistance.far must be greater than scaleByDistance.near
    Type
    DeveloperError
  • translucencyByDistance.far must be greater than translucencyByDistance.near
    Type
    DeveloperError
  • pixelOffsetScaleByDistance.far must be greater than pixelOffsetScaleByDistance.near
    Type
    DeveloperError
  • distanceDisplayCondition.far must be greater than distanceDisplayCondition.near
    Type
    DeveloperError

Label()

A Label draws viewport-aligned text positioned in the 3D scene. This constructor should not be used directly, instead create labels by calling LabelCollection#add.
Source:
See:
Throws:
  • translucencyByDistance.far must be greater than translucencyByDistance.near
    Type
    DeveloperError
  • pixelOffsetScaleByDistance.far must be greater than pixelOffsetScaleByDistance.near
    Type
    DeveloperError
  • distanceDisplayCondition.far must be greater than distanceDisplayCondition.near
    Type
    DeveloperError

ModelAnimation()

An active glTF animation. A glTF asset can contain animations. An active animation is an animation that is currently playing or scheduled to be played because it was added to a model's ModelAnimationCollection. An active animation is an instance of an animation; for example, there can be multiple active animations for the same glTF animation, each with a different start time.

Create this by calling ModelAnimationCollection#add.

Source:
See:

ModelAnimationCollection()

A collection of active model animations. Access this using Model#activeAnimations.
Source:
See:

ModelMaterial()

A model's material with modifiable parameters. A glTF material contains parameters defined by the material's technique with values defined by the technique and potentially overridden by the material. This class allows changing these values at runtime.

Use Model#getMaterial to create an instance.

Source:
See:

ModelMesh()

A model's mesh and its materials.

Use Model#getMesh to create an instance.

Source:
See:

ModelNode()

A model node with a transform for user-defined animations. A glTF asset can contain animations that target a node's transform. This class allows changing a node's transform externally so animation can be driven by another source, not just an animation in the glTF asset.

Use Model#getNode to create an instance.

Source:
See:
Example
var node = model.getNode('LOD3sp');
node.matrix = Cesium.Matrix4.fromScale(new Cesium.Cartesian3(5.0, 1.0, 1.0), node.matrix);

PointPrimitive()

A graphical point positioned in the 3D scene, that is created and rendered using a PointPrimitiveCollection. A point is created and its initial properties are set by calling PointPrimitiveCollection#add.
Source:
See:
Throws:
  • scaleByDistance.far must be greater than scaleByDistance.near
    Type
    DeveloperError
  • translucencyByDistance.far must be greater than translucencyByDistance.near
    Type
    DeveloperError
  • distanceDisplayCondition.far must be greater than distanceDisplayCondition.near
    Type
    DeveloperError

Polyline(optionsopt)

A renderable polyline. Create this by calling PolylineCollection#add
Parameters:
Name Type Attributes Description
options Object <optional>
Object with the following properties:
Properties
Name Type Attributes Default Description
show Boolean <optional>
true true if this polyline will be shown; otherwise, false.
width Number <optional>
1.0 The width of the polyline in pixels.
loop Boolean <optional>
false Whether a line segment will be added between the last and first line positions to make this line a loop.
material Material <optional>
Material.ColorType The material.
positions Array.<Cartesian3> <optional>
The positions.
id Object <optional>
The user-defined object to be returned when this polyline is picked.
distanceDisplayCondition DistanceDisplayCondition <optional>
The condition specifying at what distance from the camera that this polyline will be displayed.
Source:
See: