Class: AbstractGlobe

AbstractGlobe

Creates a sky or a planet with it own coordinate reference system and renders the globe. According to its coordinate reference system, the globe can be projected on a map.
Client implementations should not normally instantiate this class directly.

new AbstractGlobe(type, options)

Parameters:
Name Type Description
type GLOBE Type of the globe.
options AbstractGlobe.configuration Options for globe creation.
Implements:
See:
Throws:
  • Will throw an error when the options.coordinateSystem is not defined.
    Type
    ReferenceError
  • Will throw an error when options.coordinateSystem.geoideName is not part of CRS
    Type
    RangeError
  • Will throw an error when options.coordinateSystem.projectionName is not part of PROJECTION when it is defined
    Type
    RangeError

Methods


getType()

Implements:

isSky()

Implements:

dispose()

Implements:

destroy()

Implements:

refresh()

Implements:

<abstract> setBaseImagery()

Implements:

<abstract> getBaseElevation()

Implements:

addLayer()

Implements:

removeLayer()

Implements:

addAnimation()

Implements:

removeAnimation()

Implements:

<abstract> getElevation()

Implements:

getViewportGeoBound()

Implements:

getLonLatFromPixel()

Implements:

getPixelFromLonLat()

Implements:

<abstract, protected> render()

Implements:
  • Globe#render

setCoordinateSystem()

Implements:

getCoordinateSystem()

Implements:

getRenderStats()

Implements:

getRenderContext()

Implements:

setRenderContext()

Implements:

getTileManager()

Implements:

isEnabled()

Implements:

Type Definitions


dm_planet

Planet configuration data model
Type:
  • Object
Properties:
Name Type Description
canvas Object canvas object
tileErrorTreshold int tile error treshold
continuousRendering boolean continuous rendering
renderContext renderContext | null Rendering context
coordinateSystem AbstractCrs.crsFactory Coordinate reference system of the planet
shadersPath string = "../../shaders/" - Shaders location
lighting boolean = false - Lighting
backgroundColor Array.<float> = [0.0, 0.0, 0.0, 1.0] - Background color
minFar int = 0
defaultColor Array.<int> = [200, 200, 200, 255] - Default color
renderTileWithoutTexture boolean = true
publishEvent function Callback

dm_sky

Planet configuration data model
Type:
  • Object
Properties:
Name Type Argument Description
canvas Object canvas object
tileErrorTreshold int tile error treshold
continuousRendering boolean continuous rendering
renderContext renderContext <optional>
Rendering context
coordinateSystem AbstractCrs.crsFactory Coordinate reference system of the planet
lighting boolean = false - Lighting
backgroundColor Array.<float> = [0.0, 0.0, 0.0, 1.0] - Background color
minFar int
radius float
defaultColor Array.<int> = [200, 200, 200, 255] - Default color
shadersPath string = "../../shaders/" - Shaders location
renderTileWithoutTexture boolean = false
publishEvent function Callback

configuration

AbstractGlobe configuration
Type:
  • Object
Properties:
Name Type Argument Default Description
options.continuousRendering boolean <optional>
false Options that renders the globe in continue
coordinateSystem AbstractCrs.crsFactory coordinate system data model
renderContext Object <optional>
RenderContext object.
shadersPath string <optional>
../shaders/ Option for RenderContext : shader location.
tileErrorTreshold int <optional>
4 Option for RenderContext : tile error
lighting boolean <optional>
false Option for RenderContext : enable/disable lighting
canvas Object | string Option for RenderContext : Canvas element to insert in the globe
backgroundColor Array <optional>
[0.0, 0.0, 0.0, 1.0] Option for RenderContext : color for background
minFar int <optional>
0 Option for RenderContext : When 0 , no limit on far
defaultColor Array <optional>
[200, 200, 200, 255] Option for TileManager : pixel default color