SGWorld Class

This is the control class that provides SkylineGlobe functionality to the web page.

Constructor

Name

Description

Constructor

Initializes a new instance of the SGWorld class.

Methods

Name

Description

showPopup Method

Shows a pop-up window.

removePopup Method

Removes a pop-up window.

attachEvent Method

Attaches the specified function to the given SGWorld event.

detachEvent Method

Detaches the event so that it no longer calls the specified function when it fires.

Properties

Name

Description

navigate

Enables control of the camera position and orientation in the 3D world.

creator

Enables creation of objects such as polylines, labels and groups.

window

A wrapper object for all the functionalities interaction with the 3D window such as snapshots, dimensions and query pixel information.

root

The root node that holds all the objects added to the Skyline Globe control object hierarchy. Of  the SGNode type.

lastError

Contains information about the last error that occurred during a call to one of the methods of the Skyline Globe Control. This property is a normal java script error object.

Events

Name

Description

onLoadFinished Event

Fires when Skyline Globe Control finishes loading a fly file

onFileClosing Event

Fires before a fly file is closed to notify that the file is being closed

onFrame Event

Is sent in each frame, before the frame is rendered, to allow the user to perform any per frame activity (i.e. moving objects on the terrain)

onTerraExplorerMessage Event

Fires when a message object is about to be triggered

onNodeAction Event

Fires when a certain action (e.g., to fly to an object) is performed on the node object

onFileSave Event

Fires just before a fly file is saved

onRenderQualityChanged Event

Fires when the terrain quality that the user is currently viewing is updated

onInputModeChanged Event

Fires when the control Input mode is changed (e.g., switching from free flight mode to measurements mode)

onLButtonDown Event

Fires when the user presses the left mouse button in the 3D window

onLButtonUp Event

Fires when the user releases the left mouse button

onMButtonDown Event

Fires when the user presses the middle mouse button in the 3D window

onMButtonUp Event

Fires when user releases the middle mouse button

onRButtonDown Event

Fires when the user presses the Right mouse button in the 3D window

onRButtonUp Event

Fires when user releases the right mouse button

onMouseWheel Event

Fires when the user rotates the mouse wheel and encounters the wheel’s next notch.

onLButtonDblClick Event

Fires when the user double clicks the left mouse button in the 3D window

onRButtonDblClick Event

Fires when the user double clicks the right mouse button in the 3D window

onMButtonDblClick Event

Fires when the user double clicks the middle mouse button in the 3D window

onClick

Fires when the user clicks the left mouse button in the 3D window