Placemarks

This section documents classes that provide placemark-related functionality.

Class list

Author

G Element Germanium team

VisualObject

An abstract class; base class for Placemark class.

Inheritance diagram

$INHERITANCE_DIAGRAM_VisualObject

Since

Version 0.3.3.0

Summary
Constants
VisualObject types Deprecated; use Germanium Types instead.
Geometry property
GetGeometry Gets the Geometry of this VisualObject .
SetGeometry Sets the Geometry of this VisualObject .
HasGeometry Returns whether this VisualObject has a Geometry .
StyleSet property
GetStyleSet Gets the StyleSet of this VisualObject .
SetStyleSet Sets the StyleSet of this VisualObject .
HasStyleSet Returns whether this VisualObject has a StyleSet .
Interactivity property
GetInteractivity Gets whether the end-user can interact with this VisualObject using the mouse.
SetInteractivity Sets if the end-user can interact with this VisualObject using the mouse.
IsInteractive Returns whether the end-user can interact with this VisualObject using the mouse.
Maximum view distance
GetMaxViewDistance Gets the maximum view distance of this VisualObject .
SetMaxViewDistance Sets the maximum view distance of this VisualObject .
Attached to BBL property
AttachToBBLObject Attach this VisualObject to the specified BBL object (a Building , Block , or Level ).
DetachFromBBLObject Detaches this VisualObject from the BBL object it is currently attached to.
GetBBLObjectAttachedTo Gets the BBL object to which this VisualObject is attached to.
IsAttachedToBBLObject Returns true if this VisualObject is currently attached to a BBL object.
General properties
GetType Returns the type of this VisualObject .
GetHandle Gets the Handle of this VisualObject .
Visibility property
GetVisibility Gets the visibility state of this VisualObject .
SetVisibility Sets the visibility state of this VisualObject .
Show Makes this VisualObject visible.
Hide Hides this VisualObject .
IsHidden Returns true if this VisualObject is currently hidden.

Constants

VisualObject types

Deprecated; use Germanium Types instead.

Germanium.VisualObject.PlacemarkSee Placemark .

Geometry property

GetGeometry

GetGeometry : function ()

Gets the Geometry of this VisualObject .

Returns

{mixed}a PointGeometry , a LineStringGeometry , or a PolygonGeometry

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.3.3.0

SetGeometry

SetGeometry : function (geometry)

Sets the Geometry of this VisualObject .  To mark different things in the scene, you specify different Geometry types:

point VisualObjectuse PointGeometry .  Example: a “you are here” location
line VisualObjectuse LineStringGeometry .  Example: a “how to get to our shop” path
polygon VisualObjectuse PolygonGeometry .  Example: a “our show is here” area
model VisualObjectuse ModelGeometry .  Example: a “landmark” object

Parameter

{mixed} geometrya PointGeometry , a LineStringGeometry , a ModelGeometry , or a PolygonGeometry

Returns

void

Throws

Since

Version 0.3.3.0

HasGeometry

HasGeometry : function ()

Returns whether this VisualObject has a Geometry .

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.3.3.0

StyleSet property

GetStyleSet

GetStyleSet : function ()

Gets the StyleSet of this VisualObject .

Returns

StyleSet

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.3.3.0

SetStyleSet

SetStyleSet : function (styleSet)

Sets the StyleSet of this VisualObject .

Parameter

{StyleSet} styleSet StyleSet to be assigned to this VisualObject .

Returns

void

Throws

Since

Version 0.3.3.0

HasStyleSet

HasStyleSet : function ()

Returns whether this VisualObject has a StyleSet .

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.3.3.0

Interactivity property

GetInteractivity

GetInteractivity : function ()

Gets whether the end-user can interact with this VisualObject using the mouse.  Default is true.

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.3.4.0

SetInteractivity

SetInteractivity : function (bVal)

Sets if the end-user can interact with this VisualObject using the mouse.  Default is true.

Parameter

{bool} bVal

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.3.4.0

IsInteractive

IsInteractive : function ()

Returns whether the end-user can interact with this VisualObject using the mouse.  Default is true.

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.3.4.0

Maximum view distance

GetMaxViewDistance

GetMaxViewDistance : function ()

Gets the maximum view distance of this VisualObject .  When the distance between this VisualObject and the Eye is greater than the maximum view distance, this VisualObject is not shown in the scene.

The default value is 0, which means this VisualObject is always shown.

Returns

float

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.5.1

SetMaxViewDistance

SetMaxViewDistance : function (dist)

Sets the maximum view distance of this VisualObject .  When the distance between this VisualObject and the Eye is greater than the maximum view distance, this VisualObject is not shown in the scene.

Setting the value to 0 or negative makes this VisualObject to be always shown no matter how far it is from the Eye .

Parameter

{float} distthe value to be set as the maximum view distance; unit is meter

Returns

void

Throws

Since

Version 1.3.5.1

Attached to BBL property

AttachToBBLObject

AttachToBBLObject : function (inObj)

Attach this VisualObject to the specified BBL object (a Building , Block , or Level ).  If this VisualObject is currently attached to a BBL object, it will be detached from the old BBL object.

Parameter

{mixed} inObjthe BBL object to which this VisualObject will be attached to. inObj can be a Building , a Block , or a Level .

Returns

void

Throws

Since

Version 1.3.13.2

DetachFromBBLObject

DetachFromBBLObject : function ()

Detaches this VisualObject from the BBL object it is currently attached to.

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.13.2

GetBBLObjectAttachedTo

GetBBLObjectAttachedTo : function ()

Gets the BBL object to which this VisualObject is attached to.

Returns

{mixed}a Building , a Block , or a Level

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.13.2

IsAttachedToBBLObject

IsAttachedToBBLObject : function ()

Returns true if this VisualObject is currently attached to a BBL object.

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.13.2

General properties

GetType

GetType : function ()

Returns the type of this VisualObject .  See Germanium Types for possible types.

Inherited from Object .

Returns

string

Since

Version 0.3.3.0

GetHandle

GetHandle : function ()

Gets the Handle of this VisualObject .  Handles are system-generated and non-persistent.  Use a handle as a fast, lightweight alternative to passing around a VisualObject.

Inherited from Object .

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.0.0.1

Visibility property

GetVisibility

GetVisibility : function ()

Gets the visibility state of this VisualObject .

Inherited from Hideable .

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.0.10

SetVisibility

SetVisibility : function (bVal)

Sets the visibility state of this VisualObject .

Parameter

{bool} bVal

Inherited from Hideable .

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.0.10

Show

Show : function ()

Makes this VisualObject visible.  Equivalent to SetVisibility(true).

Inherited from Hideable .

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.0.10

See also

SetVisibility

Hide

Hide : function ()

Hides this VisualObject .  Equivalent to SetVisibility(false).

Inherited from Hideable .

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.0.10

See also

SetVisibility

IsHidden

IsHidden : function ()

Returns true if this VisualObject is currently hidden.  This function returns the opposite value as GetVisibility .

Inherited from Hideable .

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.0.10

See also

GetVisibility

Placemark

Represents a position marker.  A placemark is useful to mark special locations in the scene, such as:

  • a “you are here” location (a point placemark),
  • a “how to get to our shop” path (a line placemark), or
  • a “our shop is here” area (a polygon placemark).

You typically use a placemark in your web application as follows :

  • First, you create a placemark.  Use the function WebControl.CreatePlacemark .  Note that you should not instantiate the Placemark class using the JavaScript keyword ‘new’.
  • You can customize what the Placemark represents by setting its name, content, and more info URL:
nameThe name of this Placemark .  It appears in the scene as a text label near the Placemark.  Use the function SetName .
contentUser-specified text giving a full description of this Placemark (HTML is supported).  It appears in a callout balloon when this Placemark is clicked.  Use the function SetContent .
more info URLURL to a web document that contains further information relevant to this Placemark.  It appears in a callout balloon when this Placemark is clicked.  Use the function SetMoreInfoUrl .
  • You can customize the appearance of a placemark by setting its Geometry and StyleSet .  The Appearance section documents the relevant GermaniumWeb behavior.
GeometryDetermines the location of this Placemark in the scene.  Use the function SetGeometry .
  • To create a point placemark, set geometry property with a PointGeometry .
  • To create a line placemark, set geometry property with a LineStringGeometry .
  • To create a polygon placemark, set geometry property with a PolygonGeometry .  To create a model placemark, set geometry property with a ModelGeometry .
StyleSetDetermines the visual appearance of this Placemark .  Use the function SetStyleSet .
  • Next, you make the placemark visible by adding it to the scene.  Use the function WebControl.AddPlacemark .
  • After you add a placemark to the scene, you can access it by:
indexIndex is the simplest to use.  Use it when you want to retrieve all placemarks in the scene one by one.  Be careful however, as any further placemark addition or removal may change the index ordering.  Use the function WebControl.GetPlacemarkByIndex .
handleA handle is a system-generated runtime id.  Use it as a fast, lightweight alternative to passing around a placemark object that you have previously retrieved.  Unlike the index, a handle is guaranteed to be persistent for the rest of the plugin’s lifespan.  Use the function WebControl.GetPlacemarkByHandle .
  • Finally, you can remove placemarks you no longer need.
Removing a specific placemarkUse the function WebControl.RemovePlacemark .
Removing all placemarks in the sceneUse the function WebControl.RemoveAllPlacemarks .

Inheritance diagram

$INHERITANCE_DIAGRAM_Placemark

See also

Related classes

Since

Version 0.1.0.10

Summary
General properties
GetType Returns the type of this Placemark .
GetHandle Gets the Handle of this Placemark .
Entity properties
GetName Gets the name of this Placemark .
SetName Sets the name of this Placemark .
GetContent Gets the content property of this Placemark .
SetContent Sets the content property of this Placemark .
GetMoreInfoUrl Gets URL to the “more info” page about this Placemark .
SetMoreInfoUrl Sets the URL link to a page providing more info about this Placemark .
Visibility property
GetVisibility Gets the visibility state of this Placemark .
SetVisibility Sets the visibility state of this Placemark .
Show Makes this Placemark visible.
Hide Hides this Placemark .
IsHidden Returns true if this Placemark is currently hidden.
Interactivity property
GetInteractivity Gets whether the end-user can interact with this Placemark using the mouse.
SetInteractivity Sets if the end-user can interact with this Placemark using the mouse.
IsInteractive Returns whether the end-user can interact with this Placemark using the mouse.
Appearance This section documents how GermaniumWeb determines Placemark appearance.
Geometry property
GetGeometry Gets the Geometry of this Placemark .
SetGeometry Sets the Geometry of this Placemark .
HasGeometry Returns whether this Placemark has a Geometry .
StyleSet property
GetStyleSet Gets the StyleSet of this Placemark .
SetStyleSet Sets the StyleSet of this Placemark .
HasStyleSet Returns whether this Placemark has a StyleSet .
Label visibility property
GetLabelVisibility Gets whether label of this Placemark is currently visible.
SetLabelVisibility Sets label visibility of this Placemark .
HideLabel Hides label of this Placemark .
ShowLabel Makes label of this Placemark visible.
IsLabelHidden Returns true if label of this Placemark is hidden.
Max label view distance property
GetMaxLabelViewDistance Gets the maximum label view distance of this Placemark .
SetMaxLabelViewDistance Sets the maximum label view distance of this Placemark .
Max view distance property
GetMaxViewDistance Gets the maximum view distance of this Placemark .
SetMaxViewDistance Sets the maximum view distance of this Placemark .
Attached to BBL property
AttachToBBLObject Attach this Placemark to the specified BBL object (a Building , Block , or Level ).
DetachFromBBLObject Detaches this Placemark from the BBL object it is currently attached to.
GetBBLObjectAttachedTo Gets the BBL object to which this Placemark is attached to.
IsAttachedToBBLObject Returns true if this Placemark is currently attached to a BBL object.

General properties

GetType

GetType : function ()

Returns the type of this Placemark .  See Germanium Types for possible types.

Inherited from Object .

Returns

string

Since

Version 0.3.3.0

GetHandle

GetHandle : function ()

Gets the Handle of this Placemark .  Handles are system-generated and non-persistent.  Use a handle as a fast, lightweight alternative to passing around a Placemark.

Inherited from Object .

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.0.0.1

Entity properties

GetName

GetName : function ()

Gets the name of this Placemark .

Inherited from Entity .

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.0.10

SetName

SetName : function (name)

Sets the name of this Placemark .

Inherited from Entity .

Returns

void

Throws

Since

Version 0.1.0.12

GetContent

GetContent : function ()

Gets the content property of this Placemark .

Inherited from Entity .

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.1.0.21

SetContent

SetContent : function (content)

Sets the content property of this Placemark .

Notes

  • Is user-specified text giving a full description of this Placemark .
  • HTML is supported.

Parameter

{string} contentString to be assigned as content of this Placemark

Inherited from Entity .

Returns

void

Throws

Since

Version 0.1.0.21

GetMoreInfoUrl

GetMoreInfoUrl : function ()

Gets URL to the “more info” page about this Placemark .

Inherited from Entity .

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.1.0.21

SetMoreInfoUrl

SetMoreInfoUrl : function (url)

Sets the URL link to a page providing more info about this Placemark .

Parameter

{string} urlURL to be set.

Inherited from Entity .

Returns

void

Throws

Since

Version 0.1.0.21

Visibility property

GetVisibility

GetVisibility : function ()

Gets the visibility state of this Placemark .

Inherited from Hideable .

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.0.10

SetVisibility

SetVisibility : function (bVal)

Sets the visibility state of this Placemark .

Parameter

{bool} bVal

Inherited from Hideable .

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.0.10

Show

Show : function ()

Makes this Placemark visible.  Equivalent to SetVisibility(true).

Inherited from Hideable .

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.0.10

See also

SetVisibility

Hide

Hide : function ()

Hides this Placemark .  Equivalent to SetVisibility(false).

Inherited from Hideable .

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.0.10

See also

SetVisibility

IsHidden

IsHidden : function ()

Returns true if this Placemark is currently hidden.  This function returns the opposite value as GetVisibility .

Inherited from Hideable .

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.0.10

See also

GetVisibility

Interactivity property

GetInteractivity

GetInteractivity : function ()

Gets whether the end-user can interact with this Placemark using the mouse.  Default is true.

Inherited from VisualObject .

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.3.4.0

SetInteractivity

SetInteractivity : function (bVal)

Sets if the end-user can interact with this Placemark using the mouse.  Default is true.

Parameter

{bool} bVal

Inherited from VisualObject .

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.3.4.0

IsInteractive

IsInteractive : function ()

Returns whether the end-user can interact with this Placemark using the mouse.  Default is true.

Inherited from VisualObject .

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.3.4.0

Appearance

This section documents how GermaniumWeb determines Placemark appearance.

2 properties that determine how a Placemark appears in the scene are :

The Geometry property can be a PointGeometry , a LineStringGeometry , a PolygonGeometry , or a ModelGeometry .

The StyleSet property contains 3 styles: BalloonStyle , LabelStyle , and GeometryStyle .

Note that Geometry and GeometryStyle are different.  Geometry is a property in Placemark class, while GeometryStyle is a property in StyleSet class.

There are 4 possible scenarios :

1.  Geometry & GeometryStyle are missingThe Placemark appears as the default DiamondStyle .
2.  Geometry is missing, GeometryStyle is specifiedThe Placemark appears as a diamond.  The style follows the specified GeometryStyle if it is a DiamondStyle .  Otherwise, the style is the default DiamondStyle .
3.  Geometry is specified, GeometryStyle is missingThe Placemark appears according to the specified Geometry with its default style.
4.  Geometry & GeometryStyle are specifiedThe Placemark appears according to the specified Geometry .  The style follows the specified GeometryStyle if it is compatible to the specified Geometry .  Otherwise, the style is the default style of the specified Geometry .  We list default styles & compatible combinations below.

The compatible Geometry and GeometryStyle are :

The default style of a Geometry :

These default styles may change in future versions, so if you want your placemark to always look the same, we recommend assigning a GeometryStyle to it.

Geometry property

GetGeometry

GetGeometry : function ()

Gets the Geometry of this Placemark .

Inherited from VisualObject .

Returns

{mixed}a PointGeometry , a LineStringGeometry , or a PolygonGeometry

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.3.3.0

SetGeometry

SetGeometry : function (geometry)

Sets the Geometry of this Placemark .  To mark different things in the scene, you specify different Geometry types:

point Placemarkuse PointGeometry .  Example: a “you are here” location
line Placemarkuse LineStringGeometry .  Example: a “how to get to our shop” path
polygon Placemarkuse PolygonGeometry .  Example: a “our show is here” area
model Placemarkuse ModelGeometry .  Example: a “landmark” object

Parameter

{mixed} geometrya PointGeometry , a LineStringGeometry , a ModelGeometry , or a PolygonGeometry

Inherited from VisualObject .

Returns

void

Throws

Since

Version 0.3.3.0

HasGeometry

HasGeometry : function ()

Returns whether this Placemark has a Geometry .

Inherited from VisualObject .

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.3.3.0

StyleSet property

GetStyleSet

GetStyleSet : function ()

Gets the StyleSet of this Placemark .

Inherited from VisualObject .

Returns

StyleSet

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.3.3.0

SetStyleSet

SetStyleSet : function (styleSet)

Sets the StyleSet of this Placemark .

Parameter

{StyleSet} styleSet StyleSet to be assigned to this Placemark .

Inherited from VisualObject .

Returns

void

Throws

Since

Version 0.3.3.0

HasStyleSet

HasStyleSet : function ()

Returns whether this Placemark has a StyleSet .

Inherited from VisualObject .

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.3.3.0

Label visibility property

GetLabelVisibility

GetLabelVisibility : function ()

Gets whether label of this Placemark is currently visible.

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.5.1

SetLabelVisibility

SetLabelVisibility : function (bVal)

Sets label visibility of this Placemark .

Parameter

{bool} bValValue to assign as label visibility

Returns

void

Throws

Since

Version 1.3.5.1

HideLabel

HideLabel : function ()

Hides label of this Placemark .

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.5.1

ShowLabel

ShowLabel : function ()

Makes label of this Placemark visible.

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.5.1

IsLabelHidden

IsLabelHidden : function ()

Returns true if label of this Placemark is hidden.  This function returns the opposite value as GetLabelVisibility .

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.5.1

Max label view distance property

GetMaxLabelViewDistance

GetMaxLabelViewDistance : function ()

Gets the maximum label view distance of this Placemark .  When the distance between this Placemark and the Eye is greater than the maximum label view distance, the label of this Placemark is not shown in the scene.

The default value is 0, which means that the label of this Placemark is always shown not matter how far it is from the Eye .

Returns

float

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.5.1

SetMaxLabelViewDistance

SetMaxLabelViewDistance : function (dist)

Sets the maximum label view distance of this Placemark .  When the distance between this Placemark and the Eye is greater than the maximum label view distance, the label of this Placemark is not shown in the scene.

Setting the value to 0 or negative makes the label of this Placemark to be always shown no matter how for the Placemark is from the Eye .

Parameter

{float} distthe value to be set as the maximum label view distance; unit is meter

Returns

void

Throws

Since

Version 1.3.5.1

Max view distance property

GetMaxViewDistance

GetMaxViewDistance : function ()

Gets the maximum view distance of this Placemark .  When the distance between this Placemark and the Eye is greater than the maximum view distance, this Placemark is not shown in the scene.

The default value is 0, which means this Placemark is always shown.

Inherited from VisualObject .

Returns

float

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.5.1

SetMaxViewDistance

SetMaxViewDistance : function (dist)

Sets the maximum view distance of this Placemark .  When the distance between this Placemark and the Eye is greater tha the maximum view distance, this Placemark is not shown in the scene.

Setting the value to 0 or negative makes this Placemark to be always shown no matter how far it is from the Eye .

Parameter

{float} distthe value to be set as the maximum view distance; unit is meter

Inherited from VisualObject .

Returns

void

Throws

Since

Version 1.3.5.1

Attached to BBL property

AttachToBBLObject

AttachToBBLObject : function (inObj)

Attach this Placemark to the specified BBL object (a Building , Block , or Level ).  If this Placemark is currently attached to a BBL object, it will be detached from the old BBL object.

Parameter

{mixed} inObjthe BBL object to which this Placemark will be attached to. inObj ca be a Building , a Block , or a Level .

Inherited from VisualObject .

Returns

void

Throws

Since

Version 1.3.13.2

DetachFromBBLObject

DetachFromBBLObject : function ()

Detaches this Placemark from the BBL object it is currently attached to.

Inherited from VisualObject .

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.13.2

GetBBLObjectAttachedTo

GetBBLObjectAttachedTo : function ()

Gets the BBL object to which this Placemark is attached to.

Inherited from VisualObject .

Returns

{mixed}a Building , a Block , or a Level

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.13.2

IsAttachedToBBLObject

IsAttachedToBBLObject : function ()

Returns true if this Placemark is currently attached to a BBL object.

Inherited from VisualObject .

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.13.2

Geometry

An abstract class; base class for concrete geometry classes.

Inheritance diagram

Object LineStringGeometry ModelGeometry PointGeometry PolygonGeometry

See also

Since

Version 0.1.0.12

Summary
General properties
GetType Returns the type of this Geometry .
GetHandle Gets the Handle of this Geometry .
Constants
Geometry types Deprecated; use Germanium Types instead.

General properties

GetType

GetType : function ()

Returns the type of this Geometry .  See Germanium Types for possible types.

Inherited from Object .

Returns

string

Since

Version 0.3.3.0

GetHandle

GetHandle : function ()

Gets the Handle of this Geometry .  Handles are system-generated and non-persistent.  Use a handle as a fast, lightweight alternative to passing around a Geometry.

Inherited from Object .

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.0.0.1

Constants

Geometry types

Deprecated; use Germanium Types instead.

Germanium.Geometry.PointGeometrySee PointGeometry .

PointGeometry

Represents a point in the 3D scene.

You should not instantiate the PointGeometry class using the JavaScript keyword ‘new’.  Instead, use the function WebControl.CreatePointGeometry .

Inheritance diagram

$INHERITANCE_DIAGRAM_PointGeometry

See also

Since

Version 0.1.0.12

Summary
Position property
GetPosition Returns the position of this PointGeometry as a Coordinates .
GetPositionX Deprecated; use GetPosition instead.
GetPositionY Deprecated; use GetPosition instead.
GetPositionZ Deprecated; use GetPosition instead.
SetPosition Sets the position of this PointGeometry .
General properties
GetType Returns the type of this PointGeometry .
GetHandle Gets the Handle of this PointGeometry .

Position property

GetPosition

GetPosition : function ()

Returns the position of this PointGeometry as a Coordinates .

Returns

Coordinates

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.1.0.12

GetPositionX

GetPositionX : function ()

Deprecated; use GetPosition instead.  Returns the X-coordinate of this PointGeometry .

Returns

float

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.1.0.12

Deprecated in

Version 1.3.19.0

GetPositionY

GetPositionY : function ()

Deprecated; use GetPosition instead.  Returns the Y-coordinate of this PointGeometry .

Returns

float

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.1.0.12

Deprecated in

Version 1.3.19.0

GetPositionZ

GetPositionZ : function ()

Deprecated; use GetPosition instead.  Returns the Z-coordinate of this PointGeometry .

Returns

float

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.1.0.12

Deprecated in

Version 1.3.19.0

SetPosition

SetPosition : function (X,
y,
z)

Sets the position of this PointGeometry .

Parameters

{mixed} Xa Coordinates , a Vector3 , or a float
{float} yoptional
{float} zoptional

Usage

SetPosition(X)Specify position as the Coordinates object X.
SetPosition(X, y, z)Specify position as the triple float (X, y, z).

Returns

void

Throws

Since

Version 0.1.0.12

General properties

GetType

GetType : function ()

Returns the type of this PointGeometry .  See Germanium Types for possible types.

Inherited from Object .

Returns

string

Since

Version 0.3.3.0

GetHandle

GetHandle : function ()

Gets the Handle of this PointGeometry .  Handles are system-generated and non-persistent.  Use a handle as a fast, lightweight alternative to passing around a PointGeometry.

Inherited from Object .

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.0.0.1

LineStringGeometry

Represents a connected group of line segments in the 3D scene.  LineStringGeometry is ideal to mark paths in the scene.

A LineStringGeometry consists of multiple vertices.  Each vertex is a Vector3 object that represents a (x, y, z) coordinates.  The origin of the vertices is the origin of the scene.

You should not instantiate the LineStringGeometry class using the JavaScript keyword ‘new’.  Instead, use the function WebControl.CreateLineStringGeometry .

Inheritance diagram

Geometry

See also

Related classes

Since

Version 1.3.15.0

Summary
Position property
GetPosition Gets the position of this LineStringGeometry as Coordinates .
Vertex property
GetNumberOfVertices Returns the number of vertices in this LineStringGeometry .
AppendVertex Appends the specified vertex as the last vertex of this LineStringGeometry .
InsertVertex Inserts the specified vertex into this LineStringGeometry at the given index.
ReplaceVertex Replaces the vertex of this LineStringGeometry at the specified index with the specified vertex.
GetVertex Gets the vertex of this LineStringGeometry at the specified index.
RemoveVertex Removes the vertex at the specified index from this LineStringGeometry .
RemoveAllVertices Removes all vertices from this LineStringGeometry .
General properties
GetType Returns the type of this LineStringGeometry .
GetHandle Gets the Handle of this LineStringGeometry .

Position property

GetPosition

GetPosition : function ()

Gets the position of this LineStringGeometry as Coordinates .  Returns null if position has not been set.

The position is the first vertex of this LineStringGeometry .

Returns

Coordinates

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.4.9.4

Vertex property

GetNumberOfVertices

GetNumberOfVertices : function ()

Returns the number of vertices in this LineStringGeometry .

Returns

int

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.15.0

AppendVertex

AppendVertex : function (X,
y,
z)

Appends the specified vertex as the last vertex of this LineStringGeometry .

Parameter

{mixed} Xa Vector3 , a Coordinates , or a float
{float} yoptional
{float} zoptional

Returns

void

Usage

AppendVertex(X)Specify the vertex to append as X, a Vector3 object or a Coordinates object.
AppendVertex(X, y, z)Specify the vertex to append as the float triplet (X, y, z).

Throws

Since

Version 1.3.15.0

InsertVertex

InsertVertex : function (index,
X,
y,
z)

Inserts the specified vertex into this LineStringGeometry at the given index.

Parameters

{int} indexthe position to insert the new vertex
{mixed} Xa Vector3 , a Coordinates , or a float
{float} yoptional
{float} zoptional

Returns

booltrue if insertion is successful; false otherwise

Usage

InsertVertex(index, X)Specify the vertex to insert as X, a Vector3 object or a Coordinates object.
InsertVertex(index, X, y, z)Specify the vertex to insert as the float triplet (X, y, z).

Throws

Since

Version 1.3.15.0

ReplaceVertex

ReplaceVertex : function (index,
X,
y,
z)

Replaces the vertex of this LineStringGeometry at the specified index with the specified vertex.

Parameters

{int} indexthe position to put the new vertex
{mixed} Xa Vector3 , a Coordinates , or a float
{float} yoptional
{float} zoptional

Returns

booltrue if replacement is successful; false otherwise

Usage

ReplaceVertex(index, X)Specify the new vertex as X, a Vector3 object or a Coordinates object.
ReplaceVertex(index, X, y, z)Specify the new vertex as the float triplet (X, y, z).

Throws

Since

Version 1.3.15.0

GetVertex

GetVertex : function (index)

Gets the vertex of this LineStringGeometry at the specified index.

Parameter

{int} index

Returns

Vector3

Throws

Since

Version 1.3.15.0

RemoveVertex

RemoveVertex : function (index)

Removes the vertex at the specified index from this LineStringGeometry .

Parameter

{int} index

Returns

booltrue if removal is successful; false otherwise

Throws

Since

Version 1.3.15.0

RemoveAllVertices

RemoveAllVertices : function ()

Removes all vertices from this LineStringGeometry .

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.15.0

General properties

GetType

GetType : function ()

Returns the type of this LineStringGeometry .  See Germanium Types for possible types.

Inherited from Object .

Returns

string

Since

Version 0.3.3.0

GetHandle

GetHandle : function ()

Gets the Handle of this LineStringGeometry .  Handles are system-generated and non-persistent.  Use a handle as a fast, lightweight alternative to passing around a LineStringGeometry.

Inherited from Object .

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.0.0.1

PolygonGeometry

Represents a polygon in the 3D scene.  PolygonGeometry can be used to mark an area or a volume in the scene.

Origin and Vertices

A PolygonGeometry consists of an origin and multiple vertices.  The last vertex will be automatically connected to the first vertex.

The UV Space

At the default orientation, u is mapped to positive X-axis and v to negative Z-axis, as illustrated below.  The left image shows a triangle and a point in the UV space; the right one shows the same triangle and point mapped to XYZ axes.

Normal Vector

The vector perpendicular to a PolygonGeometry is called the normal vector.  At the default orientation, the normal vector points at the positive Y-axis.

Polygon Validity

A PolygonGeometry ’s vertices must follow a few rules to form a valid polygon.  A PolygonGeometry is NOT valid if:

  • it has fewer than 3 vertices (vertices introduced by extrusion are not counted),
  • it has an edge which doubles back on its neighboring edge, forming a zero degree angle at the shared vertex, or
  • any two of its edges intersect each other.

You call IsValid to check validity of a PolygonGeometry .  An invalid polygon appears unfilled, with only an outline.

You should not instantiate the PolygonGeometry class using the JavaScript keyword ‘new’.  Instead, use the function WebControl.CreatePolygonGeometry .

Inheritance diagram

$INHERITANCE_DIAGRAM_PolygonGeometry

See also

Related classes

Since

Version 1.3.13.0

Summary
Position property
GetPosition Gets the origin of this PolygonGeometry as Coordinates .
SetPosition Sets the origin of this PolygonGeometry .
Vertex property
GetNumberOfVertices Returns the number of vertices in this PolygonGeometry .
Set3DVertices Sets this PolygonGeometry to be the polygon defined by the specified array of 3D vertices.
AppendVertex Appends the specified vertex to this PolygonGeometry as the last vertex.
Append3DVertex Appends the specified 3D vertex to this PolygonGeometry as the last vertex.
InsertVertex Inserts the specified vertex to this PolygonGeometry at the given index.
Insert3DVertex Inserts the specified 3D vertex to this PolygonGeometry at the given index.
ReplaceVertex Replaces the vertex of this PolygonGeometry at the specified index with the specified vertex.
Replace3DVertex Replaces the vertex of this PolygonGeometry at the specified index with the specified 3D vertex.
GetVertex Gets the vertex of this PolygonGeometry at the specified index.
Get3DVertex Gets the 3D vertex of this PolygonGeometry at the specified index.
RemoveVertex Removes the vertex at the specified index from this PolygonGeometry .
RemoveAllVertices Removes all vertices from this PolygonGeometry .
IsValid Returns true if this PolygonGeometry is valid; returns false otherwise.
GetUpVector Gets the “up” vector of the polygon.
Normal vector & Orientation properties
GetNormal Gets the normal vector of this PolygonGeometry .
SetNormal Use PolygonGeometry.SetOrientationByNormal instead.
SetOrientationByNormal Sets the orientation of this PolygonGeometry by specifying where the polygon’s normal vector should point in the 3D scene.
SetOrientationByNormalAndUp Sets the orientation of this PolygonGeometry by specifying where the polygon’s normal and up vectors should point in the 3D scene.
GetOrientation Gets the orientation of this PolygonGeometry .
SetOrientation Sets the orientation of this PolygonGeometry .
RotateAroundUpVector Rotates this PolygonGeometry around its Up vector by the specified angle.
RotateAroundRightVector Rotates this PolygonGeometry around its Right vector by the specified angle.
RotateAroundNormalVector Rotates this PolygonGeometry around its Normal vector by the specified angle.
ExtrusionHeight property
GetExtrusionHeight Gets how high this PolygonGeometry extrudes.
SetExtrusionHeight Sets how high this PolygonGeometry extrudes.
General properties
GetType Returns the type of this PolygonGeometry .
GetHandle Gets the Handle of this PolygonGeometry .

Position property

GetPosition

GetPosition : function ()

Gets the origin of this PolygonGeometry as Coordinates .

Returns

Coordinates

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.13.0

SetPosition

SetPosition : function (X,
y,
z)

Sets the origin of this PolygonGeometry .

The origin determines the position of this PolygonGeometry in the 3D scene.  The origin is also used by a Placemark as tip of the callout opened when the placemark is activated.

Parameters

{mixed} Xa Coordinates or a float
{float} yoptional
{float} zoptional

Usage

SetPosition(X)Specify position as the Coordinates object X.
SetPosition(X, y, z)Specify position as the triple float (X, y, z).

Returns

void

Throws

Since

Version 1.3.13.0

Vertex property

GetNumberOfVertices

GetNumberOfVertices : function ()

Returns the number of vertices in this PolygonGeometry .

Returns

int

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.13.0

Set3DVertices

Set3DVertices : function (vertexArray,
normalAxis,
position)

Sets this PolygonGeometry to be the polygon defined by the specified array of 3D vertices.

If the specified 3D vertices are not coplanar, a best fit plane with the specified normal direction is used.  All 3D vertices are then projected onto the plane following the plane’s normal direction.  In this case, this function will return false.

On the other hand, if the specified 3D vertices are all on the same plane, this function will simply return true.

Parameters

{array} vertexArrayarray of Vector3 objects.
{int} normalAxis(optional) specifies the normal vector of this PolygonGeometry .  See NormalAxis for possible values.
{Vector3} position(optional) the 3D vertex to be used as the position of this PolygonGeometry .

Returns

booltrue if setting 3D vertices is successful; false if at least one vertex in vertexArray needs to be modified to make this PolygonGeometry valid.

Throws

Since

Version 1.4.5.0

AppendVertex

AppendVertex : function (U,
v)

Appends the specified vertex to this PolygonGeometry as the last vertex.

A vertex is represented as a UV coordinates that determine the location the vertex relative to the origin of this PolygonGeometry .  You set the origin using SetPosition .

Parameters

{mixed} Ua Vector2 or a float
{float} voptional

Returns

void

Usage

AppendVertex(U)Specify the vertex to append as the Vector2 object U.
AppendVertex(U, v)Specify the vertex to append as the float pair (U, v).

Throws

See also

Since

Version 1.3.13.0

Append3DVertex

Append3DVertex : function (X,
y,
z)

Appends the specified 3D vertex to this PolygonGeometry as the last vertex.

If this PolygonGeometry does not have any vertex, the specified vertex will also be used as the position of this PolygonGeometry .

If this PolygonGeometry has 2 vertices, it will be oriented to fit the plane formed by this PolygonGeometry ’s 2 vertices and the specified 3D vertex.  In this case, this function will result in either a horizontal plane (i.e. its normal is parallel the Y axis) or a vertical plane (i.e. its normal is perpendicular to the Y axis).

If this PolygonGeometry has 3 or more vertices and the specified 3D vertex is not coplanar with vertices of this PolygonGeometry , the specified 3D vertex will be projected onto the plane following the normal of this PolygonGeometry .

Parameters

{mixed} Xa Vector3 or a float
{float} yoptional
{float} zoptional

Returns

booltrue if the input vertex is appended successfully without modification; false if the input vertex is modified to make this PolygonGeometry valid.

Usage

Append3DVertex(X)Specify the 3D vertex to append as the Vector3 object X.
Append3DVertex(X, y, z)Specify the 3D vertex to append as the float triple (X, y, z).

Throws

Since

Version 1.4.5.0

InsertVertex

InsertVertex : function (index,
U,
v)

Inserts the specified vertex to this PolygonGeometry at the given index.

A vertex is represented as a UV coordinates that determine the location the vertex relative to the origin of this PolygonGeometry .  You set the origin using SetPosition .

Parameters

{int} indexthe position to insert the new vertex
{mixed} Ua Vector2 or a float
{float} voptional

Returns

booltrue if insertion is successful; false otherwise

Usage

InsertVertex(index, U)Specify the vertex to insert as the Vector2 object U.
InsertVertex(index, U, v)Specify the vertex to insert as the float pair (U, v).

Throws

See also

Since

Version 1.3.13.0

Insert3DVertex

Insert3DVertex : function (index,
X,
y,
z)

Inserts the specified 3D vertex to this PolygonGeometry at the given index.

If this PolygonGeometry does not have any vertex, the specified vertex will also be used as the position of this PolygonGeometry .

If this PolygonGeometry has 2 vertices, it will be oriented to fit the plane formed by this PolygonGeometry ’s 2 vertices and the specified 3D vertex.  In this case, this function will result in either a horizontal plane (i.e. its normal is parallel the Y axis) or a vertical plane (i.e. its normal is perpendicular to the Y axis).

If this PolygonGeometry has 3 or more vertices and the specified 3D vertex is not coplanar with vertices of this PolygonGeometry , the specified 3D vertex will be projected onto the plane following the normal of this PolygonGeometry .

Parameters

{int} indexthe position to insert the new 3D vertex
{mixed} Xa Vector3 or a float
{float} yoptional
{float} zoptional

Returns

bool

Usage

Insert3DVertex(index, X)Specify the 3D vertex to insert as the Vector3 object X.
Insert3DVertex(index, X, y, z)Specify the 3D vertex to insert as the float triple (X, y, z).

Throws

Since

Version 1.4.5.0

ReplaceVertex

ReplaceVertex : function (index,
U,
v)

Replaces the vertex of this PolygonGeometry at the specified index with the specified vertex.

A vertex is represented as a UV coordinates that determine the location the vertex relative to the origin of this PolygonGeometry .  You set the origin using SetPosition .

Parameters

{int} indexthe position to put the new vertex
{mixed} Ua Vector2 or a float
{float} voptional

Returns

booltrue if replacement is successful; false otherwise

Usage

ReplaceVertex(index, U)Specify the new vertex as the <Vertex2> object U.
ReplaceVertex(index, U, v)Specify the new vertex as the float pair (U, v).

Throws

See also

Since

Version 1.3.13.0

Replace3DVertex

Replace3DVertex : function (index,
X,
y,
z)

Replaces the vertex of this PolygonGeometry at the specified index with the specified 3D vertex.

If this PolygonGeometry has 3 or more vertices and the specified 3D vertex is not coplanar with vertices of this PolygonGeometry , the specified 3D vertex will be projected onto the plane following the normal of this PolygonGeometry .

Parameters

{int} indexthe position to put the new vertex
{mixed} Xa Vector3 or a float
{float} yoptional
{float} zoptional

Returns

booltrue if replacement is successful; false otherwise

Throws

Usage

Replace3DVertex(index, X)Specify the new 3D vertex as the Vector3 object X.
Replace3DVertex(index, X, y, z)Specify the new 3D vertex as the float triple (X, y, z).

Since

Version 1.4.5.0

GetVertex

GetVertex : function (index)

Gets the vertex of this PolygonGeometry at the specified index.

A vertex is represented as a UV coordinates that determine the location the vertex relative to the origin of this PolygonGeometry .  You set the origin using SetPosition .

Parameter

{int} index

Returns

Vector2

Throws

See also

Since

Version 1.3.13.0

Get3DVertex

Get3DVertex : function (index)

Gets the 3D vertex of this PolygonGeometry at the specified index.

Parameter

{int} index

Returns

Vector3

Throws

Since

Version 1.4.5.0

RemoveVertex

RemoveVertex : function (index)

Removes the vertex at the specified index from this PolygonGeometry .

A vertex is represented as a UV coordinates that determine the location the vertex relative to the origin of this PolygonGeometry .  You set the origin using SetPosition .

Parameter

{int} index

Returns

bool

Throws

See also

Since

Version 1.3.13.0

RemoveAllVertices

RemoveAllVertices : function ()

Removes all vertices from this PolygonGeometry .

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.13.0

IsValid

IsValid : function ()

Returns true if this PolygonGeometry is valid; returns false otherwise.  A PolygonGeometry is invalid if one of the following is true:

  • it has fewer than 3 vertices (vertices introduced by extrusion are not counted)
  • it has an edge which doubles back on its neighboring edge, forming a zero degree angle at the shared vertex
  • any two of its edges intersect each other
  • the vertices are specified in clockwise order
    • Since plugin 1.31, specifying vertices in clockwise order results in a valid PolygonGeometry .

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.13.0

GetUpVector

GetUpVector : function(unitFlag)

Gets the “up” vector of the polygon.  The up vector is the upward direction from the top of the polygon.

The up vector is synchronized with the orientation.

Parameter

{bool} unitFlagif set true, returns the up vector as a unit vector

Returns

Vector3

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.5.7.1

Normal vector & Orientation properties

GetNormal

GetNormal : function (unitFlag)

Gets the normal vector of this PolygonGeometry .  The normal vector is the direction that the flat surface of the polygon is pointing.

The normal vector is synchronized with the orientation.

Parameter

{bool} unitFlagif set true, returns the normal as a unit vector

Returns

Vector3

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.13.0

SetNormal

SetNormal : function (X,
y,
z)

Deprecated

Use PolygonGeometry.SetOrientationByNormal instead.

Returns

void

Throws

Since

Version 1.3.13.0

SetOrientationByNormal

SetOrientationByNormal : function (X,
y,
z)

Sets the orientation of this PolygonGeometry by specifying where the polygon’s normal vector should point in the 3D scene.  The up vector is arbitrarily chosen to be suitable in most cases.  For full control, use PolygonGeometry.SetOrientationByNormalAndUp instead.

Parameters

{mixed} Xa Vector3 or a float
{float} yoptional
{float} zoptional

Returns

void

Throws

Since

Version 1.5.7.1

SetOrientationByNormalAndUp

SetOrientationByNormalAndUp : function (X,
Y,
z,
xUp,
yUp,
zUp)

Sets the orientation of this PolygonGeometry by specifying where the polygon’s normal and up vectors should point in the 3D scene.  In UV space, the normal vector points away from the UV plane, and the up vector points in the positive V direction, “up” if you are looking at the UV space straight on.

Parameters

{mixed} Xa Vector3 or a float
{mixed} Ya Vector3 or a float
{float} zoptional
{float} xUpoptional
{float} yUpoptional
{float} zUpoptional

Usage

SetOrientationByNormalAndUp(vecNormal, vecTangent)Sets the polygon’s normal and up vectors in the 3D scene.
SetOrientationByNormalAndUp(1,0,0, 0,0,-1)Sets the polygon’s normal and up vectors as 3 floats each.

Returns

void

Throws

Since

Version 1.5.7.1

GetOrientation

GetOrientation : function ()

Gets the orientation of this PolygonGeometry .

The orientation is synchronized with the normal vector.

Returns

EulerAngle

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.13.0

SetOrientation

SetOrientation : function (P,
q,
r)

Sets the orientation of this PolygonGeometry .  The orientation is the EulerAngle from the vector (0, 0, 1) to this PolygonGeometry ’s Normal vector.

The orientation is synchronized with the normal vector.

Parameters

{mixed} Pan EulerAngle or a float
{float} qoptional
{float} roptional

Usage

SetOrientation(P)Specify orientation as the EulerAngle object P.
SetOrientation(P, q, r)Specify orientation as the float triple (P, q, r).

Returns

void

Throws

Since

Version 1.3.13.0

RotateAroundUpVector

RotateAroundUpVector : function (angle)

Rotates this PolygonGeometry around its Up vector by the specified angle.

Parameter

{float} angleangle of rotation (in radians)

Returns

void

Throws

Since

Version 1.3.13.0

RotateAroundRightVector

RotateAroundRightVector : function (angle)

Rotates this PolygonGeometry around its Right vector by the specified angle.

The normal vector and the orientation are synchronized.

Parameter

{float} angleangle of rotation (in radians)

Returns

void

Throws

Since

Version 1.3.13.0

RotateAroundNormalVector

RotateAroundNormalVector : function (angle)

Rotates this PolygonGeometry around its Normal vector by the specified angle.

The normal vector and the orientation are synchronized.

Parameter

{float} angleangle of rotation (in radians)

Returns

void

Throws

Since

Version 1.3.13.0

ExtrusionHeight property

GetExtrusionHeight

GetExtrusionHeight : function ()

Gets how high this PolygonGeometry extrudes.  Extrusion is always in the direction of the normal vector.

Returns

float

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.13.0

SetExtrusionHeight

SetExtrusionHeight : function (height)

Sets how high this PolygonGeometry extrudes.  Extrusion is always in the direction of the normal vector.

Extruding a PolygonGeometry does not increase its vertex count.

Parameter

{float} heightin meters

Returns

float

Throws

Since

Version 1.3.13.0

General properties

GetType

GetType : function ()

Returns the type of this PolygonGeometry .  See Germanium Types for possible types.

Inherited from Object .

Returns

string

Since

Version 0.3.3.0

GetHandle

GetHandle : function ()

Gets the Handle of this PolygonGeometry .  Handles are system-generated and non-persistent.  Use a handle as a fast, lightweight alternative to passing around a PolygonGeometry.

Inherited from Object .

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.0.0.1

ModelGeometry

Represents a model in a 3D scene.  ModelGeometry can be used to create Placemark s with arbitrary geometry.

Url

The source url specifies the geometry file from which ModelGeometry will get its geometry data.  Currently, only geometry exported in the COLLADA (.DAE) format are supported by ModelGeometry .  For more details on compatibility with COLLADA, please refer to our COLLADA exporting guide .

Origin

The origin of the ModelGeometry controls the position, orientation and scale of the Placemark ’s 3D geometry.  It affects where the loading icon (see below) will appear, and where the placemark callout’s tail will point to when opened.

By default, ModelGeometry uses the file origin of the COLLADA file as its origin.  The file origin is typically the world origin in the 3D modeling package (e.g.  Google SketchUp) from which the COLLADA file is exported.

For single-object models (e.g. a chair), it is sometimes more convenient to use the object’s origin as the ModelGeometry ’s origin.  In the COLLADA file, this origin is the origin of the first leaf node in the scene hierarchy.  You can switch to this using SetOrigin .

Loading

The ModelGeometry begins loading when its Placemark is added to the scene.  If it is the first time being used, the .DAE file will be downloaded and cached for future reuse.  While loading, the loading icon is displayed unless it is disabled by the associated ModelStyle .  The loading icon is displayed at the ModelGeometry ’s position in the scene.

When loading ends, the OnModelLoadEnds Event is raised.  Refer to Event.File loading events for more details about the event.

Error handling

If the file does not load successfully, the error icon is displayed.  GermaniumWeb will not attempt to load the file again, unless another ModelGeometry with the same url is added to the scene.

Security

GermaniumWeb allows loading of local files only when the plugin is embedded in a local HTML file.

For example, MyWebapp.html uses GermaniumWeb to load a ModelGeometry from Model.DAE.  When hosted locally, i.e. on the paths
C:\MyWebapp.html
C:\Model.DAE
GermaniumWeb will allow the file C:\Model.DAE to be loaded.

However, if MyWebapp.html is hosted on a webserver, e.g. at
http://example.com/MyWebapp.html
GermaniumWeb will not load C:\Model.DAE.

For GermaniumWeb to load C:\Model.DAE, it has to be hosted on a webserver as well, e.g. at
http://example.com/Model.DAE

You should not instantiate the ModelGeometry class using the JavaScript keyword ‘new’.  Instead, use the function WebControl.CreateModelGeometry .

Inheritance diagram

Geometry

See also

Related classes

Since

Version 1.5.3.1.

Summary
URL property
GetSourceUrl Gets the source URL of this ModelGeometry .
SetSourceUrl Sets the source URL of this ModelGeometry .
Origin property
GetOrigin Gets the origin mode of this ModelGeometry .
SetOrigin Sets the origin mode of this ModelGeometry .
Position property
GetPosition Gets the position of this ModelGeometry as a Coordinates
SetPosition Sets the position of this ModelGeometry
Orientation property
GetOrientation Gets the orientation of this ModelGeometry as an EulerAngle .
SetOrientation Sets the orientation of this ModelGeometry .
RotateAroundXAxis Rotates this ModelGeometry around its local X axis by the specified angle.
RotateAroundYAxis Rotates this ModelGeometry around its local Y axis by the specified angle.
RotateAroundZAxis Rotates this ModelGeometry around its local Z axis by the specified angle.
Scale property
GetScale Gets the scale factor of this ModelGeometry in its local X, Y and Z axes as a Vector3 .
SetScale Sets the scale of this ModelGeometry .
Constants
Origin mode Controls which origin the ModelGeometry will use as its origin in the scene.

URL property

GetSourceUrl

GetSourceUrl : function ()

Gets the source URL of this ModelGeometry .  The returned URL is always an absolute path.

Returns

string

Throws

Since

Version 1.5.3.1

SetSourceUrl

SetSourceUrl : function (url)

Sets the source URL of this ModelGeometry .

Parameter

{string} urlURL from which the model file will be fetched.  GermaniumWeb supports absolute and relative paths.  For relative paths, GermaniumWeb uses window.location as the document base URL to resolve relative paths.  You can change it by calling WebControl.SetDocumentBase .

Returns

void

Events

  • OnModelLoadEnds

Throws

Since

Version 1.5.3.1

Origin property

GetOrigin

GetOrigin : function ()

Gets the origin mode of this ModelGeometry .  The origin controls which origin the ModelGeometry will use as its origin in the scene.

Returns

intsee Origin mode for possible values

Throws

Since

Version 1.5.6.0

SetOrigin

SetOrigin : function (mode)

Sets the origin mode of this ModelGeometry .  The origin controls which origin the ModelGeometry will use as its origin in the scene.

Parameters

{int} modesee Origin mode for valid values

Returns

void

Throws

Since

Version 1.5.6.0

Position property

GetPosition

GetPosition : function ()

Gets the position of this ModelGeometry as a Coordinates

Returns

Coordinates

Throws

Since

Version 1.5.3.1

SetPosition

SetPosition : function (X,
y,
z)

Sets the position of this ModelGeometry

Parameters

{mixed} Xa Vector3 , Coordinates or a float
{float} yoptional
{float} zoptional

Usage

SetPosition(X)Specify position as the Coordinates object X.
SetPosition(X, y, z)Specify position as the triple float (X, y, z).

Returns

void

Throws

Since

Version 1.5.3.1

Orientation property

GetOrientation

GetOrientation : function ()

Gets the orientation of this ModelGeometry as an EulerAngle .

Returns

EulerAngle

Throws

Since

Version 1.5.3.1

SetOrientation

SetOrientation : function (X,
y,
z)

Sets the orientation of this ModelGeometry .

Parameters

{mixed} Xan EulerAngle or a float
{float} yoptional
{float} zoptional

Usage

SetOrientation(X)Specify orientation as an EulerAngle
SetOrientation(X, y, z)Specify orientation as a float triple, where X, y and z are rotation angles about the X, Y and Z-axes in radians, respectively.

Returns

void

Throws

Since

Version 1.5.3.1

RotateAroundXAxis

RotateAroundXAxis : function (angle)

Rotates this ModelGeometry around its local X axis by the specified angle.

Parameters

{float} angleangle of rotation (in radians)

Returns

void

Throws

Since

Version 1.5.3.1

RotateAroundYAxis

RotateAroundYAxis : function (angle)

Rotates this ModelGeometry around its local Y axis by the specified angle.

Parameters

{float} angleangle of rotation (in radians)

Returns

void

Throws

Since

Version 1.5.3.1

RotateAroundZAxis

RotateAroundZAxis : function (angle)

Rotates this ModelGeometry around its local Z axis by the specified angle.

Parameters

{float} angleangle of rotation (in radians)

Returns

void

Throws

Since

Version 1.5.3.1

Scale property

GetScale

GetScale : function ()

Gets the scale factor of this ModelGeometry in its local X, Y and Z axes as a Vector3 .

Returns

Vector3

Throws

Since

Version 1.5.3.1

SetScale

SetScale : function (X,
y,
z)

Sets the scale of this ModelGeometry .

Parameters

{mixed} Xa Vector3 , Coordinates or a float
{float} yoptional
{float} zoptional

Usage

SetScale(X)Specify scale in the ModelGeometry ’s local X, Y and Z axes as a Vector3 or Coordinates .
SetScale(X, y, z)Specify scale as a float triple, where X, y and z are the scale factors of the X, Y and Z axes, respectively.

Returns

void

Throws

Since

Version 1.5.3.1

Constants

Origin mode

Controls which origin the ModelGeometry will use as its origin in the scene.  See SetOrigin .

Germanium.ModelGeometry.Origin.Fileuses the COLLADA file’s origin
Germanium.ModelGeometry.Origin.FirstNodeuses the location of the first Node in the COLLADA file.

StyleSet

Stores Style objects that control the visual appearance of a VisualObject .  Using a StyleSet object, you can make multiple VisualObjects share the same appearance.

You should not instantiate the StyleSet class using the JavaScript keyword ‘new’.  Instead, use the function WebControl.CreateStyleSet or Placemark.GetStyleSet .

A StyleSet holds 3 styles

By default, a StyleSet does not have any of the 3 styles assigned.  In other words, calling HasGeometryStyle() or HasLabelStyle() or HasBalloonStyle() on a StyleSet object just created will return false.

See also

WebControl.CreateStyleSet

Related classes

Since

Version 0.1.0.12

Summary
General properties
GetHandle Gets the Handle of this StyleSet .
GeometryStyle property
HasGeometryStyle Returns true if this StyleSet contains a GeometryStyle .
GetGeometryStyle Gets the GeometryStyle of this StyleSet .
SetGeometryStyle Sets the GeometryStyle of this StyleSet .
ResetGeometryStyle Resets the GeometryStyle of this StyleSet to default.
LabelStyle property
HasLabelStyle Returns true if this StyleSet contains a LabelStyle .
GetLabelStyle Gets the LabelStyle of this StyleSet .
SetLabelStyle Sets the LabelStyle of this StyleSet .
ResetLabelStyle Resets the LabelStyle of this StyleSet to default.
BalloonStyle property
HasBalloonStyle Returns true if this StyleSet contains a BalloonStyle .
GetBalloonStyle Gets the BalloonStyle of this StyleSet .
SetBalloonStyle Sets the BalloonStyle of this StyleSet .
ResetBalloonStyle Resets the BalloonStyle of this StyleSet to default.
StyleSet function
RemoveAllStyles Removes GeometryStyle , LabelStyle , and BalloonStyle from this StyleSet .

General properties

GetHandle

GetHandle : function ()

Gets the Handle of this StyleSet .  Handles are system-generated and non-persistent.  Use a handle as a fast, lightweight alternative to passing around a StyleSet.

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.0.0.1

GeometryStyle property

HasGeometryStyle

HasGeometryStyle : function ()

Returns true if this StyleSet contains a GeometryStyle .

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.0.0

GetGeometryStyle

GetGeometryStyle : function ()

Gets the GeometryStyle of this StyleSet .  Returns null if this StyleSet does not have a GeometryStyle .

Returns

{mixed}an ArrowStyle , a DiamondStyle , an IconStyle , a LineStyle , or a PolygonStyle

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.1.0.15

SetGeometryStyle

SetGeometryStyle : function (geomStyle)

Sets the GeometryStyle of this StyleSet .

See Placemark.Appearance section to learn the specific behavior of GermaniumWeb when you specify a GeometryStyle that may be incompatible with the Geometry you specified.

Parameter

{mixed} geomStylean ArrowStyle , a DiamondStyle , an IconStyle , a LineStyle , a ModelStyle or a PolygonStyle

Returns

void

Throws

Usage

SetGeometryStyle(anArrowStyleObject)Specify geometry style as an ArrowStyle .
SetGeometryStyle(aDiamondStyleObject)Specify geometry style as a DiamondStyle .
SetGeometryStyle(anIconStyleObject)Specify geometry style as an IconStyle .
SetGeometryStyle(aLineStyleObject)Specify geometry style as a LineStyle .
SetGeometryStyle(aModelStyleObject)Specify geometry style as a ModelStyle .
SetGeometryStyle(aPolygonStyleObject)Specify geometry style as a PolygonStyle .

See also

Placemark.Appearance

Since

Version 0.1.0.12

ResetGeometryStyle

ResetGeometryStyle : function ()

Resets the GeometryStyle of this StyleSet to default.

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.6.0

LabelStyle property

HasLabelStyle

HasLabelStyle : function ()

Returns true if this StyleSet contains a LabelStyle .

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.0.0

GetLabelStyle

GetLabelStyle : function ()

Gets the LabelStyle of this StyleSet .  Returns null if this StyleSet does not have a LabelStyle .

Returns

LabelStyle

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.3.1.0

SetLabelStyle

SetLabelStyle : function (lblStyle)

Sets the LabelStyle of this StyleSet .

Parameter

{LabelStyle} lblStyleLabel style that controls the appearance of text label above a Placemark .

Returns

void

Throws

  • ”invalid_argument” Exception
  • ”uninitialized_plugin_object” Exception

Since

Version 0.3.1.0

ResetLabelStyle

ResetLabelStyle : function ()

Resets the LabelStyle of this StyleSet to default.

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.6.0

BalloonStyle property

HasBalloonStyle

HasBalloonStyle : function ()

Returns true if this StyleSet contains a BalloonStyle .

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.4.6.0

GetBalloonStyle

GetBalloonStyle : function ()

Gets the BalloonStyle of this StyleSet .  Returns null if this StyleSet does not have a BalloonStyle .

Returns

BalloonStyle

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.4.6.0

SetBalloonStyle

SetBalloonStyle : function (blnStyle)

Sets the BalloonStyle of this StyleSet .

BalloonStyle changes do not get applied to already-open balloons.  In other words, you should close & re-open a callout balloon after changing BalloonStyle to make sure that the change is reflected in the scene.

Parameter

{BalloonStyle} blnStyle BalloonStyle that controls the appearance of a Placemark callout balloon.

Returns

void

Throws

  • ”invalid_argument” Exception
  • ”uninitialized_plugin_object” Exception

Since

Version 1.4.6.0

ResetBalloonStyle

ResetBalloonStyle : function ()

Resets the BalloonStyle of this StyleSet to default.

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.4.6.0

StyleSet function

RemoveAllStyles

RemoveAllStyles : function ()

Removes GeometryStyle , LabelStyle , and BalloonStyle from this StyleSet .

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.1.0.12

Style

An abstract class; base class of GeometryStyle & LabelStyle classes.

Inheritance diagram

$INHERITANCE_DIAGRAM_Style

Since

Version 1.1.0.0

Summary
General properties
GetType Returns the type of this Style .
GetHandle Gets the Handle of this Style .
Constants
Style types Deprecated; use Germanium Types instead.

General properties

GetType

GetType : function ()

Returns the type of this Style .  See Germanium Types for possible types.

Inherited from Object .

Returns

string

Since

Version 0.3.3.0

GetHandle

GetHandle : function ()

Gets the Handle of this Style .  Handles are system-generated and non-persistent.  Use a handle as a fast, lightweight alternative to passing around a Style.

Inherited from Object .

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.0.0.1

Constants

Style types

Deprecated; use Germanium Types instead.

Germanium.Style.GeometryStyleSee GeometryStyle .
Germanium.Style.LabelStyleSee LabelStyle .
Germanium.Style.DiamondStyleSee DiamondStyle .
Germanium.Style.ArrowStyleSee ArrowStyle .
Germanium.Style.IconStyleSee IconStyle .

GeometryStyle

An abstract class; base class for concrete geometry style classes.

Inheritance diagram

Style ArrowStyle DiamondStyle IconStyle LineStyle ModelStyle PolygonStyle

See also

Since

Version 0.1.0.14

Summary
General properties
GetType Returns the type of this GeometryStyle .
GetHandle Gets the Handle of this GeometryStyle .
Constants
Line Pattern Controls line pattern of a LineStyle or a PolygonStyle .

General properties

GetType

GetType : function ()

Returns the type of this GeometryStyle .  See Germanium Types for possible types.

Inherited from Object .

Returns

string

Since

Version 0.3.3.0

GetHandle

GetHandle : function ()

Gets the Handle of this GeometryStyle .  Handles are system-generated and non-persistent.  Use a handle as a fast, lightweight alternative to passing around a GeometryStyle.

Inherited from Object .

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.0.0.1

Constants

Line Pattern

Controls line pattern of a LineStyle or a PolygonStyle .  See LineStyle.SetLinePattern & PolygonStyle.SetOutlinePattern .

Germanium.GeometryStyle.LinePattern.Solid
Germanium.GeometryStyle.LinePattern.Dashed1
Germanium.GeometryStyle.LinePattern.Dashed2
Germanium.GeometryStyle.LinePattern.Dashed3
Germanium.GeometryStyle.LinePattern.Dotted1
Germanium.GeometryStyle.LinePattern.Dotted2
Germanium.GeometryStyle.LinePattern.Dotted3
Germanium.GeometryStyle.LinePattern.DashDot1
Germanium.GeometryStyle.LinePattern.DashDot2

DiamondStyle

Gives a Placemark the appearance of a 3D diamond.  The placemark must have a PointGeometry object as its geometry property.

You should not instantiate the DiamondStyle class using the JavaScript keyword ‘new’.  Instead, use the function WebControl.CreateDiamondStyle .

Inheritance diagram

GeometryStyle

See also

Related classes

Since

Version 0.1.0.12

Summary
Color property
GetColor Gets the Color of this DiamondStyle .
GetColorR Deprecated; use GetColor instead.
GetColorG Deprecated; use GetColor instead.
GetColorB Deprecated; use GetColor instead.
GetColorA Deprecated; use GetColor instead.
GetColorWebRGB Returns the color of this DiamondStyle as a web color RGB hex triplet, without the prefix ‘#’.
GetColorWebRGBA Returns color of this DiamondStyle as a web color RGBA hex quartet, without the prefix ‘#’.
SetColor Sets the color of this DiamondStyle .
SetColorWeb Deprecated; use SetColor instead.
Dimensions
GetWidth Gets the width of this DiamondStyle , in meters.
SetWidth Sets the width of this DiamondStyle , in meters.
GetUpperHeight Gets the height of the upper ‘pyramid’ of this DiamondStyle , in meters.
SetUpperHeight Sets the height of the upper ‘pyramid’ of this DiamondStyle , in meters.
GetLowerHeight Gets the height of the lower ‘pyramid’ of this DiamondStyle , in meters.
SetLowerHeight Sets the height of the lower ‘pyramid’ of this DiamondStyle , in meters.
ApplyScale Uniformly scales this DiamondStyle .
General properties
GetType Returns the type of this DiamondStyle .
GetHandle Gets the Handle of this DiamondStyle .

Color property

GetColor

GetColor : function ()

Gets the Color of this DiamondStyle .

Returns

Color

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.1.0.12

GetColorR

GetColorR : function ()

Deprecated; use GetColor instead.  Gets red Color component of this DiamondStyle .

Returns

int

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.1.0.12

Deprecated in

Version 1.3.19.0

GetColorG

GetColorG : function ()

Deprecated; use GetColor instead.  Gets green Color component of this DiamondStyle .

Returns

int

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.1.0.12

Deprecated in

Version 1.3.19.0

GetColorB

GetColorB : function ()

Deprecated; use GetColor instead.  Gets blue Color component of this DiamondStyle .

Returns

int

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.1.0.12

Deprecated in

Version 1.3.19.0

GetColorA

GetColorA : function ()

Deprecated; use GetColor instead.  Gets alpha Color component of this DiamondStyle .

Returns

int

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.1.0.12

Deprecated in

Version 1.3.19.0

GetColorWebRGB

GetColorWebRGB : function ()

Returns the color of this DiamondStyle as a web color RGB hex triplet, without the prefix ‘#’.

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.1.0.12

GetColorWebRGBA

GetColorWebRGBA : function ()

Returns color of this DiamondStyle as a web color RGBA hex quartet, without the prefix ‘#’.

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.1.0.12

SetColor

SetColor : function (R,
g,
b,
a)

Sets the color of this DiamondStyle .

Parameters

{mixed} Rred color component (an int) / a web color RGB hex triplet (a string) / a web color RGBA hex quartet (a string) / a Color object
{int} goptional, green color component
{int} boptional, blue color component
{int} aoptional, alpha color component

Returns

void

Throws

Usage

SetColor( R )Specify color as R, a web color RGB triplet or a web color RGBA quartet or a Color object.
SetColor(R, g, b)Specify color as a RGB triple.
SetColor(R, g, b, a)Specify color as a RGBA quartet.

Since

Version 0.1.0.12

SetColorWeb

SetColorWeb : function (webColor)

Deprecated; use SetColor instead.  Sets color of this DiamondStyle as a RGB hex triplet.  The prefix ‘#’ is optional.  This function is equivalent to calling SetColor with a web color string.

Returns true if GermaniumWeb successfully converts input string into Color .

Parameter

{string} webColor

Sample usage

SetColorWeb(“#ffccdd”)With ‘#’ prefix; specify only RGB values.
SetColorWeb(“ffccdd”)Without ‘#’ prefix; specify only RGB values.
SetColorWeb(“ffccdd99”)Without ‘#’ prefix; specify RGBA values.

Returns

bool

Throws

Since

Version 0.1.0.15

Deprecated in

Version 1.3.19.0

Dimensions

GetWidth

GetWidth : function ()

Gets the width of this DiamondStyle , in meters.

Returns

float

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.1.0.12

SetWidth

SetWidth : function (width)

Sets the width of this DiamondStyle , in meters.

Parameter

{float} widthNew width of this DiamondStyle .

Returns

void

Throws

Since

Version 0.1.0.12

GetUpperHeight

GetUpperHeight : function ()

Gets the height of the upper ‘pyramid’ of this DiamondStyle , in meters.

Returns

float

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.1.0.12

SetUpperHeight

SetUpperHeight : function (upperheight)

Sets the height of the upper ‘pyramid’ of this DiamondStyle , in meters.

Parameter

{float} upperheightNew upper height of this DiamondStyle .

Returns

void

Throws

Since

Version 0.1.0.12

GetLowerHeight

GetLowerHeight : function ()

Gets the height of the lower ‘pyramid’ of this DiamondStyle , in meters.

Returns

float

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.1.0.12

SetLowerHeight

SetLowerHeight : function (lowerheight)

Sets the height of the lower ‘pyramid’ of this DiamondStyle , in meters.

Parameter

{float} lowerheightNew lower height of this DiamondStyle .

Returns

void

Throws

Since

Version 0.1.0.12

ApplyScale

ApplyScale : function (inScale)

Uniformly scales this DiamondStyle .  This function multiplies all dimension properties by the specified scale.

Parameter

{float} inScalescale factor to be applied

Returns

void

Throws

Since

Version 1.1.1.1

General properties

GetType

GetType : function ()

Returns the type of this DiamondStyle .  See Germanium Types for possible types.

Inherited from Object .

Returns

string

Since

Version 0.3.3.0

GetHandle

GetHandle : function ()

Gets the Handle of this DiamondStyle .  Handles are system-generated and non-persistent.  Use a handle as a fast, lightweight alternative to passing around a DiamondStyle.

Inherited from Object .

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.0.0.1

ArrowStyle

Gives a Placemark the appearance of a 3D arrow.  The placemark must have a PointGeometry object as its geometry property.

You should not instantiate the ArrowStyle class using the JavaScript keyword ‘new’.  Instead, use the function WebControl.CreateArrowStyle .

Inheritance diagram

GeometryStyle

See also

Related classes

Since

Version 1.1.1.0

Summary
Color property
GetColor Gets the Color of this ArrowStyle .
GetColorR Deprecated; use GetColor instead.
GetColorG Deprecated; use GetColor instead.
GetColorB Deprecated; use GetColor instead.
GetColorA Deprecated; use GetColor instead.
GetColorWebRGB Returns color of this ArrowStyle as a web color RGB hex triplet, without the prefix ‘#’.
GetColorWebRGBA Returns color of this ArrowStyle as a web color RGBA hex quartet, without the prefix ‘#’.
SetColor Sets the color of this ArrowStyle .
SetColorWeb Deprecated; use SetColor instead.
Dimensions
GetThickness Gets the thickness of this ArrowStyle , in meters.
SetThickness Sets the thickness of this ArrowStyle , in meters.
GetWidth Gets the width of this ArrowStyle , in meters.
SetWidth Sets the width of this ArrowStyle , in meters.
GetHeadLength Gets the arrow head length of this ArrowStyle , in meters.
SetHeadLength Sets the arrow head length of this ArrowStyle , in meters.
GetTailLength Gets the arrow tail length of this ArrowStyle , in meters.
SetTailLength Sets the arrow tail length of this ArrowStyle , in meters.
ApplyScale Uniformly scales this ArrowStyle .
Arrow head & tail styles
GetHeadStyle Gets the arrow head style of this ArrowStyle .
SetHeadStyle Sets the arrow head style of this ArrowStyle .
GetTailStyle Gets the arrow tail style of this ArrowStyle .
SetTailStyle Sets the arrow tail style of this ArrowStyle .
General properties
GetType Returns the type of this ArrowStyle .
GetHandle Gets the Handle of this ArrowStyle .
Constants
Arrow Head Style
Arrow Tail Style

Color property

GetColor

GetColor : function ()

Gets the Color of this ArrowStyle .

Returns

Color

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.1.0

GetColorR

GetColorR : function ()

Deprecated; use GetColor instead.  Gets red Color component of this ArrowStyle .

Returns

int

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.1.0

Deprecated in

Version 1.3.19.0

GetColorG

GetColorG : function ()

Deprecated; use GetColor instead.  Gets green Color component of this ArrowStyle .

Returns

int

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.1.0

Deprecated in

Version 1.3.19.0

GetColorB

GetColorB : function ()

Deprecated; use GetColor instead.  Gets blue Color component of this ArrowStyle .

Returns

int

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.1.0

Deprecated in

Version 1.3.19.0

GetColorA

GetColorA : function ()

Deprecated; use GetColor instead.  Gets alpha Color component of this ArrowStyle .

Returns

int

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.1.0

Deprecated in

Version 1.3.19.0

GetColorWebRGB

GetColorWebRGB : function ()

Returns color of this ArrowStyle as a web color RGB hex triplet, without the prefix ‘#’.

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.1.0

GetColorWebRGBA

GetColorWebRGBA : function ()

Returns color of this ArrowStyle as a web color RGBA hex quartet, without the prefix ‘#’.

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.1.0

SetColor

SetColor : function (R,
g,
b,
a)

Sets the color of this ArrowStyle .

Parameters

{mixed} Rred color component (an integer) / a web color RGB hex triplet (a string) / a web color RGBA hex quarter / a Color object
{int} goptional, green color component
{int} boptional, blue color component
{int} aoptional, alpha color component

Returns

void

Throws

Usage

SetColor( R )Specify color as R, a web color RGB hex triplet or a web color RGBA hex quartet or a Color object.
SetColor(R, g, b)Specify color as RGB color components.
SetColor(R, g, b, a)Specify color as RGBA color components.

Since

Version 1.1.1.0

SetColorWeb

SetColorWeb : function (webColor)

Deprecated; use SetColor instead.  Sets color of this ArrowStyle as a RGB hex triplet.  The prefix ‘#’ is optional.  This function is equivalent to calling SetColor with a web color string.

Returns true if GermaniumWeb successfully converts input string into Color .

Sample usage

SetColorWeb(“#ffccdd”)With ‘#’ prefix; specify only RGB values.
SetColorWeb(“ffccdd”)Without ‘#’ prefix; specify only RGB values.
SetColorWeb(“ffccdd99”)Without ‘#’ prefix; specify RGBA values.

Returns

bool

Throws

Since

Version 1.1.1.0

Deprecated in

Version 1.3.19.0

Dimensions

GetThickness

GetThickness : function ()

Gets the thickness of this ArrowStyle , in meters.

Returns

float

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.1.0

SetThickness

SetThickness : function(thickness)

Sets the thickness of this ArrowStyle , in meters.

Returns

void

Throws

Since

Version 1.1.1.0

GetWidth

GetWidth : function ()

Gets the width of this ArrowStyle , in meters.

Returns

float

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.1.1

SetWidth

SetWidth : function (width)

Sets the width of this ArrowStyle , in meters.

Parameter

{float} width

Returns

void

Throws

Since

Version 1.1.1.1

GetHeadLength

GetHeadLength : function ()

Gets the arrow head length of this ArrowStyle , in meters.

Returns

float

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.1.1

SetHeadLength

SetHeadLength : function (headLength)

Sets the arrow head length of this ArrowStyle , in meters.

Parameter

{float} headLength

Returns

void

Throws

Since

Version 1.1.1.1

GetTailLength

GetTailLength : function ()

Gets the arrow tail length of this ArrowStyle , in meters.

Returns

float

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.1.1

SetTailLength

SetTailLength : function (tailLength)

Sets the arrow tail length of this ArrowStyle , in meters.

Parameter

{float} tailLength

Returns

void

Throws

Since

Version 1.1.1.1

ApplyScale

ApplyScale : function (inScale)

Uniformly scales this ArrowStyle .  This function multiplies all dimension properties by the specified scale.

Parameter

{float} inScalescale factor to be applied

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.1.1

Arrow head & tail styles

GetHeadStyle

GetHeadStyle : function ()

Gets the arrow head style of this ArrowStyle .  See ArrowStyle.Constants to see available styles.

Returns

int

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.1.0

SetHeadStyle

SetHeadStyle : function (headStyle)

Sets the arrow head style of this ArrowStyle .  See ArrowStyle.Constants to see available styles.

Returns

void

Throws

Since

Version 1.1.1.0

GetTailStyle

GetTailStyle : function ()

Gets the arrow tail style of this ArrowStyle .  See ArrowStyle.Constants to see available styles.

Returns

int

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.1.0

SetTailStyle

SetTailStyle : function (tailStyle)

Sets the arrow tail style of this ArrowStyle .  See ArrowStyle.Constants to see available styles.

Returns

void

Throws

Since

Version 1.1.1.0

General properties

GetType

GetType : function ()

Returns the type of this ArrowStyle .  See Germanium Types for possible types.

Inherited from Object .

Returns

string

Since

Version 0.3.3.0

GetHandle

GetHandle : function ()

Gets the Handle of this ArrowStyle .  Handles are system-generated and non-persistent.  Use a handle as a fast, lightweight alternative to passing around an ArrowStyle.

Inherited from Object .

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.0.0.1

Constants

Arrow Head Style

You use arrow head style in your code like this example: Germanium.ArrowStyle.HeadSimple

HeadSimpleRight-triangle shape; default value.
HeadTaperedVV shape.
HeadChevronChevron shape.
HeadDoubleDouble arrow head.

Arrow Tail Style

You use arrow tail style in your code like this example: Germanium.ArrowStyle.TailSimple

TailSimpleDefault value.
TailHeadTwo-headed arrow.

IconStyle

Gives a Placemark the appearance of a 2D image icon.  The placemark must have a PointGeometry object as its geometry property.

IconStyle shows a Placemark using a 2D icon Image .  The image has a special pixel called the hotspot that will be placed on the placemark’s position.

Notes

  • When the plugin attempts to show an icon placemark with a null Image , the plugin uses a default image with a properly set hotspot.
  • When the plugin attempts to show an icon placemark with a non-null Image but null hotspot location, the plugin uses the default value of (“50%”, “50%”), i.e. the center of the icon image.

You should not instantiate the IconStyle class using the JavaScript keyword ‘new’.  Instead, use the function WebControl.CreateIconStyle .

Inheritance diagram

GeometryStyle

See also

Related classes

Since

Version 1.1.5.1

Summary
Image property
HasImage Returns whether this IconStyle has an icon Image .
GetImage Gets the icon Image of this IconStyle .
SetImage Sets the icon Image of this IconStyle .
ResetImage Resets the icon Image of this IconStyle to default.
Hotspot property
HasHotspotX Returns whether this IconStyle ’s hotspot location has an X-component.
GetHotspotX Gets X-component of the hotspot location for this IconStyle .
SetHotspotX Sets position X-component of the hotspot of this IconStyle .
ResetHotspotX Resets this IconStyle ’s X-component of hotspot location to default.
HasHotspotY Returns whether this IconStyle ’s hotspot location has a Y-component.
GetHotspotY Gets Y-component of the hotspot location for this IconStyle .
SetHotspotY Sets position Y-component of the hotspot of this IconStyle .
ResetHotspotY Resets this IconStyle ’s Y-component of hotspot location to default.
SetHotspot Sets the hotspot position of this IconStyle .
OcclusionMode property
GetOcclusionMode Gets the occlusion mode of this IconStyle .
SetOcclusionMode Sets the occlusion mode of this IconStyle .
General properties
GetType Returns the type of this IconStyle .
GetHandle Gets the Handle of this IconStyle .
Constants
Occlusion mode

Image property

HasImage

HasImage : function ()

Returns whether this IconStyle has an icon Image .

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.5.1

GetImage

GetImage : function ()

Gets the icon Image of this IconStyle .

Returns

Image

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.5.1

SetImage

SetImage : function (image)

Sets the icon Image of this IconStyle .  The specified image will be shown in the scene to represent the Placemark associated with this IconStyle .

Parameter

{Image} image Image to be assigned to this IconStyle

Returns

void

Throws

  • ”invalid_argument” Exception
  • ”uninitialized_plugin_object” Exception

Since

Version 1.1.5.1

ResetImage

ResetImage : function ()

Resets the icon Image of this IconStyle to default.

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.6.0

Hotspot property

HasHotspotX

HasHotspotX : function ()

Returns whether this IconStyle ’s hotspot location has an X-component.

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.6.0

GetHotspotX

GetHotspotX : function ()

Gets X-component of the hotspot location for this IconStyle .

Returns

string

Throws

  • ”invalid_argument” Exception
  • ”uninitialized_plugin_object” Exception

Since

Version 1.1.5.1

SetHotspotX

SetHotspotX : function (strX)

Sets position X-component of the hotspot of this IconStyle .  The hotspot is the point on the icon Image that will be put at the position of the Placemark associated with this IconStyle .

You can specify the location of the hotspot in 2 ways :

  • using pixel as unit, for example “25px”
  • using fraction, for example “50%”

Parameter

{string} strXX-component of the hotspot location

Returns

void

Throws

  • ”invalid_argument” Exception
  • ”uninitialized_plugin_object” Exception

Since

Version 1.1.5.1

ResetHotspotX

ResetHotspotX : function ()

Resets this IconStyle ’s X-component of hotspot location to default.

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.6.0

HasHotspotY

HasHotspotY : function ()

Returns whether this IconStyle ’s hotspot location has a Y-component.

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.6.0

GetHotspotY

GetHotspotY : function ()

Gets Y-component of the hotspot location for this IconStyle .

Returns

string

Throws

  • ”invalid_argument” Exception
  • ”uninitialized_plugin_object” Exception

Since

Version 1.1.5.1

SetHotspotY

SetHotspotY : function (strY)

Sets position Y-component of the hotspot of this IconStyle .  The hotspot is the point on the icon Image that will be put at the position of the Placemark associated with this IconStyle .

You can specify the location of the hotspot in 2 ways :

  • using pixel as unit, for example “25px”
  • using fraction, for example “50%”

Parameter

{string} strYY-component of the hotspot location

Returns

void

Throws

  • ”invalid_argument” Exception
  • ”uninitialized_plugin_object” Exception

Since

Version 1.1.5.1

ResetHotspotY

ResetHotspotY : function ()

Resets this IconStyle ’s Y-component of hotspot location to default.

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.1.6.0

SetHotspot

SetHotspot : function (strX,
strY)

Sets the hotspot position of this IconStyle .

IconStyle shows a Placemark as a 2D icon Image .  The hotspot is the point on the icon image to be located at the placemark position.

You can specify the location of the hotspot in 2 ways :

  • using pixel as unit, for example “25px”
  • using fraction, for example “50%”

Typical hotspot locations

(“0%”, “0%”)upper left corner
(“0%”, “100%”)upper right corner
(“100%”, “0%”)lower left corner
(“50%”, “50%”)center

Parameters

{string} strXX-component of hotspot location
{string} strYY-component of hotspot location

Returns

void

Throws

  • ”invalid_argument” Exception
  • ”uninitialized_plugin_object” Exception

Since

Version 1.1.5.1

OcclusionMode property

GetOcclusionMode

GetOcclusionMode : function ()

Gets the occlusion mode of this IconStyle .  The occlusion mode controls whether the icon will appear x-rayed when it is obstructed by other objects in the 3D scene

Returns

intsee Occlusion mode for possible values

Throws

Since

Version 1.5.12.0

SetOcclusionMode

SetOcclusionMode : function (mode)

Sets the occlusion mode of this IconStyle .  The occlusion mode controls whether the icon will appear x-rayed when it is obstructed by other objects in the 3D scene

Parameters

{int} modesee Occlusion mode for valid values

Returns

void

Throws

Since

Version 1.5.12.0

General properties

GetType

GetType : function ()

Returns the type of this IconStyle .  See Germanium Types for possible types.

Inherited from Object .

Returns

string

Since

Version 0.3.3.0

GetHandle

GetHandle : function ()

Gets the Handle of this IconStyle .  Handles are system-generated and non-persistent.  Use a handle as a fast, lightweight alternative to passing around an IconStyle.

Inherited from Object .

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.0.0.1

Constants

Occlusion mode

Germanium.IconStyle.OcclusionMode.Fadeicon will appear x-rayed when occluded
Germanium.IconStyle.OcclusionMode.Noneicon will remain opaque when occluded

LineStyle

Controls the appearance of a Placemark that has a LineStringGeometry object as its geometry property.

You should not instantiate the LineStyle class using the JavaScript keyword ‘new’.  Instead, use the function WebControl.CreateLineStyle .

Inheritance diagram

GeometryStyle

See also

Related classes

Since

Version 1.3.15.0

Summary
Line color property
GetLineColor Gets the line color of this LineStyle .
GetLineColorWebRGB Get the line color of this LineStyle as web color RGB hex triplet.
GetLineColorWebRGBA Get the line color of this LineStyle as web color RGBA hex quartet.
SetLineColor Sets line color of this LineStyle .
Line pattern & pattern scale properties
GetLinePattern Gets line pattern of this LineStyle , such as solid or dashed.
SetLinePattern Sets line pattern of this LineStyle , such as solid or dashed.
GetLinePatternScale Gets the line pattern scale of this LineStyle .
SetLinePatternScale Gets the line pattern scale of this LineStyle .
Line width property
GetLineWidth Gets the line width of this LineStyle in pixels.
SetLineWidth Sets line width of this LineStyle in pixels.
Animation mode property
GetAnimationMode Gets the animation mode of this LineStyle .
SetAnimationMode Sets the animation mode of this LineStyle .
Constants
Animation mode Controls how line pattern is animated.

Line color property

GetLineColor

GetLineColor : function ()

Gets the line color of this LineStyle .

Returns

Color

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.15.0

GetLineColorWebRGB

GetLineColorWebRGB : function ()

Get the line color of this LineStyle as web color RGB hex triplet.

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.19.0

GetLineColorWebRGBA

GetLineColorWebRGBA : function ()

Get the line color of this LineStyle as web color RGBA hex quartet.

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.19.0

SetLineColor

SetLineColor : function (R,
g,
b,
a)

Sets line color of this LineStyle .

Parameters

{mixed} Rred color component (an int) / a web color RGB hex triplet (a string) / a web color RGBA hex quartet (a string) / a Color object
{int} goptional, green color component
{int} boptional, blue color component
{int} aoptional, alpha color component

Returns

void

Throws

Usage

SetLineColor( R )Specify color as R, a web color RGB hex triplet or a web color RGBA hex quartet or a Color object.
SetLineColor(R, g, b)Specify color as RGB color components.
SetLineColor(R, g, b, a)Specify color as RGBA color components.

Since

Version 1.3.15.0

Line pattern & pattern scale properties

GetLinePattern

GetLinePattern : function ()

Gets line pattern of this LineStyle , such as solid or dashed.

The default value is Germanium.GeometryStyle.LinePattern.Solid.

Returns

intsee GeometryStyle.Line Pattern for possible values

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.15.0

SetLinePattern

SetLinePattern : function (pattern)

Sets line pattern of this LineStyle , such as solid or dashed.

Parameter

{int} patternsee GeometryStyle.Line Pattern for valid values

Returns

void

Throws

Since

Version 1.3.15.0

GetLinePatternScale

GetLinePatternScale : function ()

Gets the line pattern scale of this LineStyle .  Line pattern scale controls the length of line pattern.  Greater values result in long dashes and dots.

The default value is 1.  Possible value range is [1, 256].

Returns

int

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.15.0

SetLinePatternScale

SetLinePatternScale : function (scale)

Gets the line pattern scale of this LineStyle .  Line pattern scale controls the length of line pattern.  Greater values result in long dashes and dots.

Parameter

{int} scalepossible value range is [1, 256].

Returns

void

Throws

Since

Version 1.3.15.0

Line width property

GetLineWidth

GetLineWidth : function ()

Gets the line width of this LineStyle in pixels.  The width value is clamped in the range [1, 10].

Returns

float

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.15.0

SetLineWidth

SetLineWidth : function (width)

Sets line width of this LineStyle in pixels.  The width value is clamped in the range [1, 10].

Parameter

{float} widthvalue to be set as line width

Returns

void

Throws

Since

Version 1.3.15.0

Animation mode property

GetAnimationMode

GetAnimationMode : function ()

Gets the animation mode of this LineStyle .  Animation mode controls how line pattern is animated in the scene.

Returns

intsee Animation mode for possible values

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.15.0

SetAnimationMode

SetAnimationMode : function (mode)

Sets the animation mode of this LineStyle .  Animation mode controls how line pattern is animated in the scene.

Parameter

{int} modesee Animation mode for valid values

Returns

void

Throws

Since

Version 1.3.15.0

Constants

Animation mode

Controls how line pattern is animated.  See SetAnimationMode .

Germanium.LineStyle.Animation.Noneno animation
Germanium.LineStyle.Animation.Forwardforward animation
Germanium.LineStyle.Animation.Backwardbackward animation

Note that older Intel video cards may encounter bugs when the line is partially out of the view.  The line animation may appear to move backward, or to suddenly speed up.  If you encounter this, try updating your video drivers.

ModelStyle

Controls the appearance of a Placemark that has a ModelGeometry object as its geometry property.

You should not instantiate the ModelStyle class using the JavaScript keyword ‘new’.  Instead, use the function WebControl.CreateModelStyle .

Inheritance diagram

GeometryStyle

See also

Related classes

Since

Version 1.5.5.5

Summary
Functions
SetUseLoadingIcon Sets the value of the UseLoadingIcon flag.
GetUseLoadingIcon Gets the value of the UseLoadingIcon flag.

Functions

SetUseLoadingIcon

SetUseLoadingIcon : function (bVal)

Sets the value of the UseLoadingIcon flag.  If set to true, GermaniumWeb will display a loading icon at the model’s position (See ModelGeometry.SetPosition ) while it is being downloaded and loaded to memory.

Parameter

{bool} bValValue to be set

Returns

void

Throws

Since

Version 1.5.5.5

GetUseLoadingIcon

GetUseLoadingIcon : function ()

Gets the value of the UseLoadingIcon flag.  If set to true, GermaniumWeb will display a loading icon at the model’s position (See ModelGeometry.SetPosition ) while it is being downloaded and loaded to memory.

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.5.5.5

PolygonStyle

Controls the appearance of a Placemark that has a PolygonGeometry object as its geometry property.

You should not instantiate the PolygonStyle class using the JavaScript keyword ‘new’.  Instead, use the function WebControl.CreatePolygonStyle .

Inheritance diagram

$INHERITANCE_DIAGRAM_PolygonStyle

See also

Related classes

Since

Version 1.3.14.0

Summary
Fill properties
GetFillColor Gets the fill Color of this PolygonStyle .
GetFillColorWebRGB Gets the fill Color of this PolygonStyle as web color RGB hex triplet.
GetFillColorWebRGBA Gets the fill Color of this PolygonStyle as web color RGBA hex quartet.
SetFillColor Sets the fill Color of this PolygonStyle .
HasFillImage Returns whether this PolygonStyle has a fill Image .
GetFillImage Gets the fill Image of this PolygonStyle .
SetFillImage Sets the fill Image of this PolygonStyle .
ResetFillImage Resets the fill Image to default.
SetFillImageTilingFactor When SetFillImage is used, this modifies the number of times the image is repeated.
GetFillImageTilingFactor Gets the fill image tiling factor as a Vector2 .
SetFillImageTilingOffset When SetFillImage is used, this modifies the position of the image on the polygon.
GetFillImageTilingOffset Gets the fill image tiling offset as a Vector2 .
GetFillMode Gets the fill mode of this PolygonStyle .
SetFillMode Sets the fill mode of this PolygonStyle .
Outline properties
GetOutlineColor Gets the outline Color of this PolygonStyle .
GetOutlineColorWebRGB Gets the outline color of this PolygonStyle as web color RGB hex triplet.
GetOutlineColorWebRGBA Gets the outline Color of this PolygonStyle as web color RGBA hex quartet.
SetOutlineColor Sets the outline Color of this PolygonStyle .
GetOutlinePattern Gets the outline pattern of this PolygonStyle , such as solid or dashed.
SetOutlinePattern Sets the outline pattern of this PolygonStyle , such as solid or dashed.
GetOutlineWidth Gets the outline width of this PolygonStyle in pixels.
SetOutlineWidth Sets the outline width of this PolygonStyle in pixels.
Smooth threshold property
GetSmoothThreshold Gets the smoothing threshold of this PolygonStyle in radians.
SetSmoothThreshold Sets the smoothing threshold of this PolygonStyle in radians.
Scene lighting property
GetUseSceneLighting Gets the value of the UseSceneLighting flag.
SetUseSceneLighting Sets the value of the UseSceneLighting flag.
General properties
GetType Returns the type of this PolygonStyle .
GetHandle Gets the Handle of this PolygonStyle .
Constants
Polygon Fill Mode Controls how a PolygonStyle is shown in the scene.

Fill properties

GetFillColor

GetFillColor : function ()

Gets the fill Color of this PolygonStyle .

Returns

Color

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.14.0

GetFillColorWebRGB

GetFillColorWebRGB : function ()

Gets the fill Color of this PolygonStyle as web color RGB hex triplet.

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.19.0

GetFillColorWebRGBA

GetFillColorWebRGBA : function ()

Gets the fill Color of this PolygonStyle as web color RGBA hex quartet.

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.19.0

SetFillColor

SetFillColor : function (R,
g,
b,
a)

Sets the fill Color of this PolygonStyle .  This color is in effect if fill mode is Fill, FillAndOutline, or FillAndOutlineWithSide and the fill image ( SetFillImage ) is <b>not</b> specified.

Parameters

{mixed} Rred color component (an int) / a web color RGB hex triplet (a string) / a web color RGBA hex quartet / a Color object
{int} goptional, green color component
{int} boptional, blue color component
{int} aoptional, alpha color component

Returns

void

Throws

Usage

SetFillColor( R )Specify fill color as R, a web color RGB hex triplet or a web color RGBA hex quartet or a Color object.
SetFillColor(R, g, b)Specify fill color as RGB color components.
SetFillColor(R, g, b, a)Specify fill color as RGBA color components.

See also

SetFillMode

Since

Version 1.3.14.0

HasFillImage

HasFillImage : function ()

Returns whether this PolygonStyle has a fill Image .

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.5.7.0

GetFillImage

GetFillImage : function ()

Gets the fill Image of this PolygonStyle .

Returns

Image

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.5.7.0

SetFillImage

SetFillImage : function (image)

Sets the fill Image of this PolygonStyle .  The fill Image is in effect if the fill mode is Fill, FillAndOutline, or FillAndOutlineWithSide.

By default, the specified image will be stretched to fit the PolygonGeometry of the placemark.  This behavior can be modified by SetFillImageTilingFactor and SetFillImageTilingOffset .

If both the fill Image and fill Color are specified, the fill image will take precedence after the file has been loaded.  In other words, the fill color will be shown until the file has been loaded.  However, the fill Color ’s alpha will still be applied on top of the fill Image after it has been loaded.

Parameter

{Image} image Image to be assigned to this PolygonStyle

Returns

void

Throws

  • ”invalid_argument” Exception
  • ”uninitialized_plugin_object” Exception

See also

PolygonStyle.SetFillColor

Since

Version 1.5.7.0

ResetFillImage

ResetFillImage : function ()

Resets the fill Image to default.

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.5.7.0

SetFillImageTilingFactor

SetFillImageTilingFactor : function(U,
v)

When SetFillImage is used, this modifies the number of times the image is repeated.  For example, a value of (2, 1) fits 2 image tiles horizontally and 1 image tile vertically to the polygon’s extents.

The default value is (1, 1), i.e. a single tile.

If SetFillImageTilingOffset is also used, the offset is applied before the tiling factor.

Parameter

{mixed} Ua Vector2 or a float
{float} voptional

Returns

void

Usage

SetFilImageTilingFactor(U)Specify the horizontal and vertical tiling factors as the Vector2 (U).
SetFilImageTilingFactor(U, v)Specify the horizontal and vertical tiling factors as the float pair (U, v).

Throws

Since

Version 1.5.10.0

GetFillImageTilingFactor

GetFillImageTilingFactor : function ()

Gets the fill image tiling factor as a Vector2 .

Returns

Vector2

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.5.10.0

SetFillImageTilingOffset

SetFillImageTilingOffset : function(U,
v)

When SetFillImage is used, this modifies the position of the image on the polygon.  The tile is moved towards the right and upwards in the polygon’s UV space by a fraction of the polygon’s width and height.  For example, a value of (0.5, 0.2) offsets the image tile by 50% of the polygon’s width to the right and 20% of the polygon’s height upwards.

The default value is (0, 0), i.e. no offset.

If SetFillImageTilingFactor is also used, this offset is applied before the tiling factor.

Parameter

{mixed} Ua Vector2 or a float
{float} voptional

Returns

void

Usage

SetFilImageTilingOffset(U)Specify the horizontal and vertical tiling offsets as the Vector2 (U).
SetFilImageTilingOffset(U, v)Specify the horizontal and vertical tiling offsets as the float pair (U, v).

Throws

Since

Version 1.5.10.0

GetFillImageTilingOffset

GetFillImageTilingOffset : function ()

Gets the fill image tiling offset as a Vector2 .

Returns

Vector2

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.5.10.0

GetFillMode

GetFillMode : function ()

Gets the fill mode of this PolygonStyle .  Fill mode controls how this PolygonStyle is shown in the scene.  See the possible values and what they mean in Polygon Fill Mode .

Returns

intsee Polygon Fill Mode for possible values

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.14.0

SetFillMode

SetFillMode : function (mode)

Sets the fill mode of this PolygonStyle .  Fill mode controls how this PolygonStyle is shown in the scene.  See the possible values and what they mean in Polygon Fill Mode .

Parameter

{int} modesee Polygon Fill Mode for valid values

Returns

void

Throws

Since

Version 1.3.14.0

Outline properties

GetOutlineColor

GetOutlineColor : function ()

Gets the outline Color of this PolygonStyle .

Returns

Color

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.14.0

GetOutlineColorWebRGB

GetOutlineColorWebRGB : function ()

Gets the outline color of this PolygonStyle as web color RGB hex triplet.

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.19.0

GetOutlineColorWebRGBA

GetOutlineColorWebRGBA : function ()

Gets the outline Color of this PolygonStyle as web color RGBA hex quartet.

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.19.0

SetOutlineColor

SetOutlineColor : function (R,
g,
b,
a)

Sets the outline Color of this PolygonStyle .  This color is in effect if fill mode is Outline, OutlineWithSide, FillAndOutline, or FillAndOutlineWithSide.

Parameters

{mixed} Rred color component (an int) / a web color RGB triplet (a string) / a web color RGBA color quartet (a string) / a Color object
{int} goptional, green color component
{int} boptional, blue color component
{int} aoptional, alpha color component

Returns

void

Throws

Usage

SetOutlineColor( R )Specify outline color as R, a web color RGB hex triplet or a web color RGBA hex quartet or a Color object.
SetOutlineColor(R, g, b)Specify outline color as RGB color components.
SetOutlineColor(R, g, b, a)Specify outline color as RGBA color components.

See also

SetFillMode

Since

Version 1.3.14.0

GetOutlinePattern

GetOutlinePattern : function ()

Gets the outline pattern of this PolygonStyle , such as solid or dashed.

The default value is Germanium.GeometryStyle.LinePattern.Solid.

Returns

intsee GeometryStyle.Line Pattern for possible values

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.15.0

SetOutlinePattern

SetOutlinePattern : function (pattern)

Sets the outline pattern of this PolygonStyle , such as solid or dashed.

Parameter

{int} patternsee GeometryStyle.Line Pattern for valid values

Returns

void

Throws

Since

Version 1.3.15.0

GetOutlineWidth

GetOutlineWidth : function ()

Gets the outline width of this PolygonStyle in pixels.  The width value is clamped in the range [1, 10].

Returns

float

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.14.0

SetOutlineWidth

SetOutlineWidth : function (width)

Sets the outline width of this PolygonStyle in pixels.  The width value is clamped in the range [1, 10].

Parameter

{float} widthvalue to be set as outline width

Returns

void

Throws

Since

Version 1.3.14.0

Smooth threshold property

GetSmoothThreshold

GetSmoothThreshold : function ()

Gets the smoothing threshold of this PolygonStyle in radians.

This only applies to the extruded sides of the polygon.  If the angle between 2 adjacent faces is less than or equal to the smoothing threshold, the normals between the 2 faces are smoothed.  For example, in the case of a cylinder, adjusting this value may result in a smoothed cylinder or a faceted one.  Edges that are smoothed are not drawn even when the fill mode is set with OutlineWithSide.

Returns

floatvalue is in the range [0.0, PI]

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.3.15.2

SetSmoothThreshold

SetSmoothThreshold : function (threshold)

Sets the smoothing threshold of this PolygonStyle in radians.

This only applies to the extruded sides of the polygon.  If the angle between 2 adjacent faces is less than or equal to the smoothing threshold, the normals between the 2 faces are smoothed.  For example, in the case of a cylinder, adjusting this value may result in a smoothed cylinder or a faceted one.  Edges that are smoothed are not drawn even when the fill mode is set with OutlineWithSide.

The default value is 0.0.  The possible value range is [0.0, PI].

Parameter

{float} thresholdin radians

Returns

void

Throws

Since

Version 1.3.15.2

Scene lighting property

GetUseSceneLighting

GetUseSceneLighting : function ()

Gets the value of the UseSceneLighting flag.  If set to true, the polygon will be rendered with the same realtime lighting as the buildings.  If set to false, the polygon will be rendered purely with the FillImage texture if specified, or in the FillColor if not.

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.5.7.0

SetUseSceneLighting

SetUseSceneLighting : function (bVal)

Sets the value of the UseSceneLighting flag.  If set to true, the polygon will be rendered with the same realtime lighting as the buildings.  If set to false, the polygon will be rendered purely with the FillImage texture if specified, or in the FillColor if not.

Parameter

{bool} bValValue to assign to the UseSceneLighting flag.

Returns

void

Throws

Since

Version 1.5.7.0

General properties

GetType

GetType : function ()

Returns the type of this PolygonStyle .  See Germanium Types for possible types.

Inherited from Object .

Returns

string

Since

Version 0.3.3.0

GetHandle

GetHandle : function ()

Gets the Handle of this PolygonStyle .  Handles are system-generated and non-persistent.  Use a handle as a fast, lightweight alternative to passing around a PolygonStyle.

Inherited from Object .

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.0.0.1

Constants

Polygon Fill Mode

Controls how a PolygonStyle is shown in the scene.  See SetFillMode .

Germanium.PolygonStyle.Fillpolygon is shaded
Germanium.PolygonStyle.Outlinepolygon has an outline
Germanium.PolygonStyle.OutlineWithSidepolygon and the extruded sides are outlined
Germanium.PolygonStyle.FillAndOutlinepolygon is both shaded and outlined
Germanium.PolygonStyle.FillAndOutlineWithSidepolygon is shaded and outlined, including the extruded sides

LabelStyle

Controls the appearance of label text of a VisualObject .

You should not instantiate the LabelStyle class using the JavaScript keyword ‘new’.  Instead, use the function WebControl.CreateLabelStyle or StyleSet.GetLabelStyle .

Inheritance diagram

Style

See also

Related classes

Since

Version 0.3.1.0

Summary
Text color property
GetTextColor Gets text Color of this LabelStyle .
GetTextColorWebRGB Gets text color of this LabelStyle as web color RGB hex triplet.
GetTextColorWebRGBA Gets text color of this LabelStyle as web color RGBA hex quartet.
SetTextColor Sets text Color of this LabelStyle .
SetTextColorWeb Deprecated; use SetTextColor instead.
General properties
GetType Returns the type of this LabelStyle .
GetHandle Gets the Handle of this LabelStyle .

Text color property

GetTextColor

GetTextColor : function ()

Gets text Color of this LabelStyle .

Returns

Color

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.3.1.0

GetTextColorWebRGB

GetTextColorWebRGB : function ()

Gets text color of this LabelStyle as web color RGB hex triplet.

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.3.1.0

GetTextColorWebRGBA

GetTextColorWebRGBA : function ()

Gets text color of this LabelStyle as web color RGBA hex quartet.

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 0.3.1.0

SetTextColor

SetTextColor : function (R,
g,
b,
a)

Sets text Color of this LabelStyle .

Parameters

{mixed} Rred color component (an integer) / a web color RGB hex triplet (a string) / a web color RGBA hex quartet (a string) / a Color object
{int} goptional, green color component
{int} boptional, blue color component
{int} aoptional, optional alpha color component

Returns

void

Throws

  • ”invalid_argument” Exception
  • ”length_error” Exception
  • ”uninitialized_plugin_oject” Exception

Usage

SetTextColor( R )Specifies text color as R, a web color RGB hex triplet or a web color RGBA hex quartet or a Color object.
SetTextColor(R, g, b)Specifies text color as RGB color components.
SetTextColor(R, g, b, a)Spefifies text color as RGBA color components.

Since

Version 0.3.1.0

SetTextColorWeb

SetTextColorWeb : function (webColor)

Deprecated; use SetTextColor instead.  Sets text color of this LabelStyle as a RGB hex triplet.  The prefix ‘#’ is optional.  This function is equivalent to calling SetTextColor with a web color string.

Returns true if GermaniumWeb successfully converts input string into Color .

Parameters

{string} webColor

Sample usage

SetColorWeb(“#ffccdd”)With ‘#’ prefix; specify only RGB values.
SetColorWeb(“ffccdd”)Without ‘#’ prefix; specify only RGB values.
SetColorWeb(“ffccdd99”)Without ‘#’ prefix; specify RGBA values.

Returns

bool

Throws

  • ”invalid_argument” Exception
  • ”uninitialized_plugin_oject” Exception

Since

Version 1.1.1.1

Deprecated in

Version 1.3.19.0

General properties

GetType

GetType : function ()

Returns the type of this LabelStyle .  See Germanium Types for possible types.

Inherited from Object .

Returns

string

Since

Version 0.3.3.0

GetHandle

GetHandle : function ()

Gets the Handle of this LabelStyle .  Handles are system-generated and non-persistent.  Use a handle as a fast, lightweight alternative to passing around a LabelStyle.

Inherited from Object .

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.0.0.1

BalloonStyle

Controls callout appearance of a Placemark .

BalloonStyle changes do not get applied to already-open balloons.  In other words, you should close & re-open a callout balloon after changing BalloonStyle to make sure that the change is reflected in the scene.

You should not instantiate the BalloonStyle class using the JavaScript keyword ‘new’.  Instead, use the function WebControl.CreateBalloonStyle or StyleSet.GetBalloonStyle .

Inheritance diagram

Style

See also

Related classes

Since

Version 1.4.6.0

Summary
Close button visibility
GetCloseButtonVisibility Gets close button visibility of this BalloonStyle .
SetCloseButtonVisibility Sets close button visibility of this BalloonStyle .
HideCloseButton Hides close button of this BalloonStyle .
ShowCloseButton Shows close button of this BalloonStyle .
IsCloseButtonHidden Returns if close button of this BalloonStyle is hidden.
Background color property
GetBackgroundColor Gets background Color of this BalloonStyle .
GetBackgroundColorWebRGB Gets background color of this BalloonStyle as web color RGB hex triplet.
GetBackgroundColorWebRGBA Gets background color of this BalloonStyle as web color RGBA hex quartet.
SetBackgroundColor Sets background Color of this BalloonStyle .
Outline color property
GetOutlineColor Gets outline Color of this BalloonStyle .
GetOutlineColorWebRGB Gets outline color of this BalloonStyle as web color RGB hex triplet.
GetOutlineColorWebRGBA Gets outline color of this BalloonStyle as web color RGBA hex quartet.
SetOutlineColor Sets outline Color of this BalloonStyle .
General properties
GetType Returns the type of this BalloonStyle .
GetHandle Gets the Handle of this BalloonStyle .

Close button visibility

GetCloseButtonVisibility

GetCloseButtonVisibility : function ()

Gets close button visibility of this BalloonStyle .

Default value is true.

Returns

bool

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.4.6.1

SetCloseButtonVisibility

SetCloseButtonVisibility : function (bVal)

Sets close button visibility of this BalloonStyle .

Default value is true.

Parameter

{bool} bValValue to assign as close button visibility

Returns

void

Throws

Since

Version 1.4.6.1

HideCloseButton

HideCloseButton : function ()

Hides close button of this BalloonStyle .

By default, the close button is shown.

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.4.6.1

ShowCloseButton

ShowCloseButton : function ()

Shows close button of this BalloonStyle .

By default, the close button is shown.

Returns

void

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.4.6.1

IsCloseButtonHidden

IsCloseButtonHidden : function ()

Returns if close button of this BalloonStyle is hidden.  This function returns the opposite value as GetCloseButtonVisibility .

By default, the close button is shown.

Returns

booltrue if close button is hidden; false if close button is visible

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.4.6.1

Background color property

GetBackgroundColor

GetBackgroundColor : function ()

Gets background Color of this BalloonStyle .

Default background color is (255, 255, 255, 255).  Background color alpha value is always 255.

Returns

Color

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.4.6.1

GetBackgroundColorWebRGB

GetBackgroundColorWebRGB : function ()

Gets background color of this BalloonStyle as web color RGB hex triplet.

Default background color is “FFFFFF”.

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.4.6.1

GetBackgroundColorWebRGBA

GetBackgroundColorWebRGBA : function ()

Gets background color of this BalloonStyle as web color RGBA hex quartet.

Default background color is “FFFFFFFF”.  Background color alpha value is always “FF”.

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.4.6.1

SetBackgroundColor

SetBackgroundColor : function (R,
g,
b,
a)

Sets background Color of this BalloonStyle .

Default background color is (255, 255, 255, 255) or “FFFFFFFF”.  Background color alpha value is always 255 or “FF”.

Parameters

{mixed} Rred color component (an integer) / a web color RGB hex triplet (a string) / a web color RGBA hex quartet (a string) / a Color object
{int} goptional, green color component
{int} boptional, blue color component
{int} aoptional, alpha color component.  Alpha value is fixed to 255.

Returns

void

Throws

Usage

SetBackgroundColor( R )Specifies background color as R, a web color RGB hex triplet or a web color RGBA hex quartet or a Color object.
SetBackgroundColor(R, g, b)Specifies background color as RGB color components.
SetBackgroundColor(R, g, b, a)Spefifies background color as RGBA color components.

Since

Version 1.4.6.1

Outline color property

GetOutlineColor

GetOutlineColor : function ()

Gets outline Color of this BalloonStyle .

Default outline color is (102, 102, 102, 127).

Returns

Color

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.4.6.1

GetOutlineColorWebRGB

GetOutlineColorWebRGB : function ()

Gets outline color of this BalloonStyle as web color RGB hex triplet.

Default outline color is “666666”.

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.4.6.1

GetOutlineColorWebRGBA

GetOutlineColorWebRGBA : function ()

Gets outline color of this BalloonStyle as web color RGBA hex quartet.

Default outline color is “6666667F”.

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.4.6.1

SetOutlineColor

SetOutlineColor : function (R,
g,
b,
a)

Sets outline Color of this BalloonStyle .

Default outline color is (102, 102, 102, 127) or “6666667F”.

Parameters

{mixed} Rred color component (an integer) / a web color RGB hex triplet (a string) / a web color RGBA hex quartet (a string) / a Color object
{int} goptional, green color component
{int} boptional, blue color component
{int} aoptional, optional alpha color component

Returns

void

Throws

Usage

SetOutlineColor( R )Specifies outline color as R, a web color RGB hex triplet or a web color RGBA hex quartet or a Color object.
SetOutlineColor(R, g, b)Specifies outline color as RGB color components.
SetOutlineColor(R, g, b, a)Spefifies outline color as RGBA color components.

Since

Version 1.4.6.1

General properties

GetType

GetType : function ()

Returns the type of this BalloonStyle .  See Germanium Types for possible types.

Inherited from Object .

Returns

string

Since

Version 0.3.3.0

GetHandle

GetHandle : function ()

Gets the Handle of this BalloonStyle .  Handles are system-generated and non-persistent.  Use a handle as a fast, lightweight alternative to passing around a BalloonStyle.

Inherited from Object .

Returns

string

Throws

”uninitialized_plugin_object” Exception

Since

Version 1.0.0.1

Represents a position marker.
GetGeometry : function ()
Gets the Geometry of this VisualObject.
An abstract class; base class for concrete geometry classes.
An abstract class; base class for Placemark class.
SetGeometry : function (geometry)
Sets the Geometry of this VisualObject.
HasGeometry : function ()
Returns whether this VisualObject has a Geometry.
GetStyleSet : function ()
Gets the StyleSet of this VisualObject.
Stores Style objects that control the visual appearance of a VisualObject.
SetStyleSet : function (styleSet)
Sets the StyleSet of this VisualObject.
HasStyleSet : function ()
Returns whether this VisualObject has a StyleSet.
GetInteractivity : function ()
Gets whether the end-user can interact with this VisualObject using the mouse.
SetInteractivity : function (bVal)
Sets if the end-user can interact with this VisualObject using the mouse.
IsInteractive : function ()
Returns whether the end-user can interact with this VisualObject using the mouse.
GetMaxViewDistance : function ()
Gets the maximum view distance of this VisualObject.
SetMaxViewDistance : function (dist)
Sets the maximum view distance of this VisualObject.
AttachToBBLObject : function (inObj)
Attach this VisualObject to the specified BBL object (a Building, Block, or Level).
Represents a building (for example “Suntec City”).
Represents a block or a wing (for example “Tower 1” in Suntec City).
Represents a level (for example “basement level” of Tower 1 in Suntec City).
DetachFromBBLObject : function ()
Detaches this VisualObject from the BBL object it is currently attached to.
GetBBLObjectAttachedTo : function ()
Gets the BBL object to which this VisualObject is attached to.
IsAttachedToBBLObject : function ()
Returns true if this VisualObject is currently attached to a BBL object.
GetType : function ()
Returns the type of this VisualObject.
GetHandle : function ()
Gets the Handle of this VisualObject.
GetVisibility : function ()
Gets the visibility state of this VisualObject.
SetVisibility : function (bVal)
Sets the visibility state of this VisualObject.
Show : function ()
Makes this VisualObject visible.
Hide : function ()
Hides this VisualObject.
IsHidden : function ()
Returns true if this VisualObject is currently hidden.
GetType : function ()
Returns the type of this Placemark.
GetHandle : function ()
Gets the Handle of this Placemark.
GetName : function ()
Gets the name of this Placemark.
SetName : function (name)
Sets the name of this Placemark.
GetContent : function ()
Gets the content property of this Placemark.
SetContent : function (content)
Sets the content property of this Placemark.
GetMoreInfoUrl : function ()
Gets URL to the “more info” page about this Placemark.
SetMoreInfoUrl : function (url)
Sets the URL link to a page providing more info about this Placemark.
GetVisibility : function ()
Gets the visibility state of this Placemark.
SetVisibility : function (bVal)
Sets the visibility state of this Placemark.
Show : function ()
Makes this Placemark visible.
Hide : function ()
Hides this Placemark.
IsHidden : function ()
Returns true if this Placemark is currently hidden.
GetInteractivity : function ()
Gets whether the end-user can interact with this Placemark using the mouse.
SetInteractivity : function (bVal)
Sets if the end-user can interact with this Placemark using the mouse.
IsInteractive : function ()
Returns whether the end-user can interact with this Placemark using the mouse.
GetGeometry : function ()
Gets the Geometry of this Placemark.
SetGeometry : function (geometry)
Sets the Geometry of this Placemark.
HasGeometry : function ()
Returns whether this Placemark has a Geometry.
GetStyleSet : function ()
Gets the StyleSet of this Placemark.
SetStyleSet : function (styleSet)
Sets the StyleSet of this Placemark.
HasStyleSet : function ()
Returns whether this Placemark has a StyleSet.
GetLabelVisibility : function ()
Gets whether label of this Placemark is currently visible.
SetLabelVisibility : function (bVal)
Sets label visibility of this Placemark.
HideLabel : function ()
Hides label of this Placemark.
ShowLabel : function ()
Makes label of this Placemark visible.
IsLabelHidden : function ()
Returns true if label of this Placemark is hidden.
GetMaxLabelViewDistance : function ()
Gets the maximum label view distance of this Placemark.
SetMaxLabelViewDistance : function (dist)
Sets the maximum label view distance of this Placemark.
GetMaxViewDistance : function ()
Gets the maximum view distance of this Placemark.
SetMaxViewDistance : function (dist)
Sets the maximum view distance of this Placemark.
AttachToBBLObject : function (inObj)
Attach this Placemark to the specified BBL object (a Building, Block, or Level).
DetachFromBBLObject : function ()
Detaches this Placemark from the BBL object it is currently attached to.
GetBBLObjectAttachedTo : function ()
Gets the BBL object to which this Placemark is attached to.
IsAttachedToBBLObject : function ()
Returns true if this Placemark is currently attached to a BBL object.
GetType : function ()
Returns the type of this Geometry.
GetHandle : function ()
Gets the Handle of this Geometry.
GetPosition : function ()
Returns the position of this PointGeometry as a Coordinates.
Represents a point in the 3D scene.
Represents a point in 3D Cartesian space.
GetPositionX : function ()
Deprecated; use GetPosition instead.
GetPositionY : function ()
Deprecated; use GetPosition instead.
GetPositionZ : function ()
Deprecated; use GetPosition instead.
SetPosition : function (X,
y,
z)
Sets the position of this PointGeometry.
GetType : function ()
Returns the type of this PointGeometry.
GetHandle : function ()
Gets the Handle of this PointGeometry.
GetPosition : function ()
Gets the position of this LineStringGeometry as Coordinates.
Represents a connected group of line segments in the 3D scene.
GetNumberOfVertices : function ()
Returns the number of vertices in this LineStringGeometry.
AppendVertex : function (X,
y,
z)
Appends the specified vertex as the last vertex of this LineStringGeometry.
InsertVertex : function (index,
X,
y,
z)
Inserts the specified vertex into this LineStringGeometry at the given index.
ReplaceVertex : function (index,
X,
y,
z)
Replaces the vertex of this LineStringGeometry at the specified index with the specified vertex.
GetVertex : function (index)
Gets the vertex of this LineStringGeometry at the specified index.
RemoveVertex : function (index)
Removes the vertex at the specified index from this LineStringGeometry.
RemoveAllVertices : function ()
Removes all vertices from this LineStringGeometry.
GetType : function ()
Returns the type of this LineStringGeometry.
GetHandle : function ()
Gets the Handle of this LineStringGeometry.
GetPosition : function ()
Gets the origin of this PolygonGeometry as Coordinates.
Represents a polygon in the 3D scene.
SetPosition : function (X,
y,
z)
Sets the origin of this PolygonGeometry.
GetNumberOfVertices : function ()
Returns the number of vertices in this PolygonGeometry.
Set3DVertices : function (vertexArray,
normalAxis,
position)
Sets this PolygonGeometry to be the polygon defined by the specified array of 3D vertices.
AppendVertex : function (U,
v)
Appends the specified vertex to this PolygonGeometry as the last vertex.
Append3DVertex : function (X,
y,
z)
Appends the specified 3D vertex to this PolygonGeometry as the last vertex.
InsertVertex : function (index,
U,
v)
Inserts the specified vertex to this PolygonGeometry at the given index.
Insert3DVertex : function (index,
X,
y,
z)
Inserts the specified 3D vertex to this PolygonGeometry at the given index.
ReplaceVertex : function (index,
U,
v)
Replaces the vertex of this PolygonGeometry at the specified index with the specified vertex.
Replace3DVertex : function (index,
X,
y,
z)
Replaces the vertex of this PolygonGeometry at the specified index with the specified 3D vertex.
GetVertex : function (index)
Gets the vertex of this PolygonGeometry at the specified index.
Get3DVertex : function (index)
Gets the 3D vertex of this PolygonGeometry at the specified index.
RemoveVertex : function (index)
Removes the vertex at the specified index from this PolygonGeometry.
RemoveAllVertices : function ()
Removes all vertices from this PolygonGeometry.
IsValid : function ()
Returns true if this PolygonGeometry is valid; returns false otherwise.
GetUpVector : function(unitFlag)
Gets the “up” vector of the polygon.
GetNormal : function (unitFlag)
Gets the normal vector of this PolygonGeometry.
SetNormal : function (X,
y,
z)
Use PolygonGeometry.SetOrientationByNormal instead.
SetOrientationByNormal : function (X,
y,
z)
Sets the orientation of this PolygonGeometry by specifying where the polygon’s normal vector should point in the 3D scene.
SetOrientationByNormalAndUp : function (X,
Y,
z,
xUp,
yUp,
zUp)
Sets the orientation of this PolygonGeometry by specifying where the polygon’s normal and up vectors should point in the 3D scene.
GetOrientation : function ()
Gets the orientation of this PolygonGeometry.
SetOrientation : function (P,
q,
r)
Sets the orientation of this PolygonGeometry.
RotateAroundUpVector : function (angle)
Rotates this PolygonGeometry around its Up vector by the specified angle.
RotateAroundRightVector : function (angle)
Rotates this PolygonGeometry around its Right vector by the specified angle.
RotateAroundNormalVector : function (angle)
Rotates this PolygonGeometry around its Normal vector by the specified angle.
GetExtrusionHeight : function ()
Gets how high this PolygonGeometry extrudes.
SetExtrusionHeight : function (height)
Sets how high this PolygonGeometry extrudes.
GetType : function ()
Returns the type of this PolygonGeometry.
GetHandle : function ()
Gets the Handle of this PolygonGeometry.
GetSourceUrl : function ()
Gets the source URL of this ModelGeometry.
Represents a model in a 3D scene.
SetSourceUrl : function (url)
Sets the source URL of this ModelGeometry.
GetOrigin : function ()
Gets the origin mode of this ModelGeometry.
SetOrigin : function (mode)
Sets the origin mode of this ModelGeometry.
GetPosition : function ()
Gets the position of this ModelGeometry as a Coordinates
SetPosition : function (X,
y,
z)
Sets the position of this ModelGeometry
GetOrientation : function ()
Gets the orientation of this ModelGeometry as an EulerAngle.
Represents an orientation in 3D space in the form of Euler angles.
SetOrientation : function (X,
y,
z)
Sets the orientation of this ModelGeometry.
RotateAroundXAxis : function (angle)
Rotates this ModelGeometry around its local X axis by the specified angle.
RotateAroundYAxis : function (angle)
Rotates this ModelGeometry around its local Y axis by the specified angle.
RotateAroundZAxis : function (angle)
Rotates this ModelGeometry around its local Z axis by the specified angle.
GetScale : function ()
Gets the scale factor of this ModelGeometry in its local X, Y and Z axes as a Vector3.
Represents a vector with 3 components.
SetScale : function (X,
y,
z)
Sets the scale of this ModelGeometry.
GetHandle : function ()
Gets the Handle of this StyleSet.
HasGeometryStyle : function ()
Returns true if this StyleSet contains a GeometryStyle.
An abstract class; base class for concrete geometry style classes.
GetGeometryStyle : function ()
Gets the GeometryStyle of this StyleSet.
SetGeometryStyle : function (geomStyle)
Sets the GeometryStyle of this StyleSet.
ResetGeometryStyle : function ()
Resets the GeometryStyle of this StyleSet to default.
HasLabelStyle : function ()
Returns true if this StyleSet contains a LabelStyle.
Controls the appearance of label text of a VisualObject.
GetLabelStyle : function ()
Gets the LabelStyle of this StyleSet.
SetLabelStyle : function (lblStyle)
Sets the LabelStyle of this StyleSet.
ResetLabelStyle : function ()
Resets the LabelStyle of this StyleSet to default.
HasBalloonStyle : function ()
Returns true if this StyleSet contains a BalloonStyle.
Controls callout appearance of a Placemark.
GetBalloonStyle : function ()
Gets the BalloonStyle of this StyleSet.
SetBalloonStyle : function (blnStyle)
Sets the BalloonStyle of this StyleSet.
ResetBalloonStyle : function ()
Resets the BalloonStyle of this StyleSet to default.
RemoveAllStyles : function ()
Removes GeometryStyle, LabelStyle, and BalloonStyle from this StyleSet.
GetType : function ()
Returns the type of this Style.
An abstract class; base class of GeometryStyle & LabelStyle classes.
GetHandle : function ()
Gets the Handle of this Style.
GetType : function ()
Returns the type of this GeometryStyle.
GetHandle : function ()
Gets the Handle of this GeometryStyle.
Controls the appearance of a Placemark that has a LineStringGeometry object as its geometry property.
Controls the appearance of a Placemark that has a PolygonGeometry object as its geometry property.
GetColor : function ()
Gets the Color of this DiamondStyle.
Represents a color.
Gives a Placemark the appearance of a 3D diamond.
GetColorR : function ()
Deprecated; use GetColor instead.
GetColorG : function ()
Deprecated; use GetColor instead.
GetColorB : function ()
Deprecated; use GetColor instead.
GetColorA : function ()
Deprecated; use GetColor instead.
GetColorWebRGB : function ()
Returns the color of this DiamondStyle as a web color RGB hex triplet, without the prefix ‘#’.
GetColorWebRGBA : function ()
Returns color of this DiamondStyle as a web color RGBA hex quartet, without the prefix ‘#’.
SetColor : function (R,
g,
b,
a)
Sets the color of this DiamondStyle.
SetColorWeb : function (webColor)
Deprecated; use SetColor instead.
GetWidth : function ()
Gets the width of this DiamondStyle, in meters.
SetWidth : function (width)
Sets the width of this DiamondStyle, in meters.
GetUpperHeight : function ()
Gets the height of the upper ‘pyramid’ of this DiamondStyle, in meters.
SetUpperHeight : function (upperheight)
Sets the height of the upper ‘pyramid’ of this DiamondStyle, in meters.
GetLowerHeight : function ()
Gets the height of the lower ‘pyramid’ of this DiamondStyle, in meters.
SetLowerHeight : function (lowerheight)
Sets the height of the lower ‘pyramid’ of this DiamondStyle, in meters.
ApplyScale : function (inScale)
Uniformly scales this DiamondStyle.
GetType : function ()
Returns the type of this DiamondStyle.
GetHandle : function ()
Gets the Handle of this DiamondStyle.
GetColor : function ()
Gets the Color of this ArrowStyle.
Gives a Placemark the appearance of a 3D arrow.
GetColorR : function ()
Deprecated; use GetColor instead.
GetColorG : function ()
Deprecated; use GetColor instead.
GetColorB : function ()
Deprecated; use GetColor instead.
GetColorA : function ()
Deprecated; use GetColor instead.
GetColorWebRGB : function ()
Returns color of this ArrowStyle as a web color RGB hex triplet, without the prefix ‘#’.
GetColorWebRGBA : function ()
Returns color of this ArrowStyle as a web color RGBA hex quartet, without the prefix ‘#’.
SetColor : function (R,
g,
b,
a)
Sets the color of this ArrowStyle.
SetColorWeb : function (webColor)
Deprecated; use SetColor instead.
GetThickness : function ()
Gets the thickness of this ArrowStyle, in meters.
SetThickness : function(thickness)
Sets the thickness of this ArrowStyle, in meters.
GetWidth : function ()
Gets the width of this ArrowStyle, in meters.
SetWidth : function (width)
Sets the width of this ArrowStyle, in meters.
GetHeadLength : function ()
Gets the arrow head length of this ArrowStyle, in meters.
SetHeadLength : function (headLength)
Sets the arrow head length of this ArrowStyle, in meters.
GetTailLength : function ()
Gets the arrow tail length of this ArrowStyle, in meters.
SetTailLength : function (tailLength)
Sets the arrow tail length of this ArrowStyle, in meters.
ApplyScale : function (inScale)
Uniformly scales this ArrowStyle.
GetHeadStyle : function ()
Gets the arrow head style of this ArrowStyle.
SetHeadStyle : function (headStyle)
Sets the arrow head style of this ArrowStyle.
GetTailStyle : function ()
Gets the arrow tail style of this ArrowStyle.
SetTailStyle : function (tailStyle)
Sets the arrow tail style of this ArrowStyle.
GetType : function ()
Returns the type of this ArrowStyle.
GetHandle : function ()
Gets the Handle of this ArrowStyle.
HasImage : function ()
Returns whether this IconStyle has an icon Image.
Gives a Placemark the appearance of a 2D image icon.
Represets a 2D image.
GetImage : function ()
Gets the icon Image of this IconStyle.
SetImage : function (image)
Sets the icon Image of this IconStyle.
ResetImage : function ()
Resets the icon Image of this IconStyle to default.
HasHotspotX : function ()
Returns whether this IconStyle’s hotspot location has an X-component.
GetHotspotX : function ()
Gets X-component of the hotspot location for this IconStyle.
SetHotspotX : function (strX)
Sets position X-component of the hotspot of this IconStyle.
ResetHotspotX : function ()
Resets this IconStyle’s X-component of hotspot location to default.
HasHotspotY : function ()
Returns whether this IconStyle’s hotspot location has a Y-component.
GetHotspotY : function ()
Gets Y-component of the hotspot location for this IconStyle.
SetHotspotY : function (strY)
Sets position Y-component of the hotspot of this IconStyle.
ResetHotspotY : function ()
Resets this IconStyle’s Y-component of hotspot location to default.
SetHotspot : function (strX,
strY)
Sets the hotspot position of this IconStyle.
GetOcclusionMode : function ()
Gets the occlusion mode of this IconStyle.
SetOcclusionMode : function (mode)
Sets the occlusion mode of this IconStyle.
GetType : function ()
Returns the type of this IconStyle.
GetHandle : function ()
Gets the Handle of this IconStyle.
GetLineColor : function ()
Gets the line color of this LineStyle.
GetLineColorWebRGB : function ()
Get the line color of this LineStyle as web color RGB hex triplet.
GetLineColorWebRGBA : function ()
Get the line color of this LineStyle as web color RGBA hex quartet.
SetLineColor : function (R,
g,
b,
a)
Sets line color of this LineStyle.
GetLinePattern : function ()
Gets line pattern of this LineStyle, such as solid or dashed.
SetLinePattern : function (pattern)
Sets line pattern of this LineStyle, such as solid or dashed.
GetLinePatternScale : function ()
Gets the line pattern scale of this LineStyle.
SetLinePatternScale : function (scale)
Gets the line pattern scale of this LineStyle.
GetLineWidth : function ()
Gets the line width of this LineStyle in pixels.
SetLineWidth : function (width)
Sets line width of this LineStyle in pixels.
GetAnimationMode : function ()
Gets the animation mode of this LineStyle.
SetAnimationMode : function (mode)
Sets the animation mode of this LineStyle.
SetUseLoadingIcon : function (bVal)
Sets the value of the UseLoadingIcon flag.
GetUseLoadingIcon : function ()
Gets the value of the UseLoadingIcon flag.
GetFillColor : function ()
Gets the fill Color of this PolygonStyle.
GetFillColorWebRGB : function ()
Gets the fill Color of this PolygonStyle as web color RGB hex triplet.
GetFillColorWebRGBA : function ()
Gets the fill Color of this PolygonStyle as web color RGBA hex quartet.
SetFillColor : function (R,
g,
b,
a)
Sets the fill Color of this PolygonStyle.
HasFillImage : function ()
Returns whether this PolygonStyle has a fill Image.
GetFillImage : function ()
Gets the fill Image of this PolygonStyle.
SetFillImage : function (image)
Sets the fill Image of this PolygonStyle.
ResetFillImage : function ()
Resets the fill Image to default.
SetFillImageTilingFactor : function(U,
v)
When SetFillImage is used, this modifies the number of times the image is repeated.
GetFillImageTilingFactor : function ()
Gets the fill image tiling factor as a Vector2.
Represents a vector with 2 components.
SetFillImageTilingOffset : function(U,
v)
When SetFillImage is used, this modifies the position of the image on the polygon.
GetFillImageTilingOffset : function ()
Gets the fill image tiling offset as a Vector2.
GetFillMode : function ()
Gets the fill mode of this PolygonStyle.
SetFillMode : function (mode)
Sets the fill mode of this PolygonStyle.
GetOutlineColor : function ()
Gets the outline Color of this PolygonStyle.
GetOutlineColorWebRGB : function ()
Gets the outline color of this PolygonStyle as web color RGB hex triplet.
GetOutlineColorWebRGBA : function ()
Gets the outline Color of this PolygonStyle as web color RGBA hex quartet.
SetOutlineColor : function (R,
g,
b,
a)
Sets the outline Color of this PolygonStyle.
GetOutlinePattern : function ()
Gets the outline pattern of this PolygonStyle, such as solid or dashed.
SetOutlinePattern : function (pattern)
Sets the outline pattern of this PolygonStyle, such as solid or dashed.
GetOutlineWidth : function ()
Gets the outline width of this PolygonStyle in pixels.
SetOutlineWidth : function (width)
Sets the outline width of this PolygonStyle in pixels.
GetSmoothThreshold : function ()
Gets the smoothing threshold of this PolygonStyle in radians.
SetSmoothThreshold : function (threshold)
Sets the smoothing threshold of this PolygonStyle in radians.
GetUseSceneLighting : function ()
Gets the value of the UseSceneLighting flag.
SetUseSceneLighting : function (bVal)
Sets the value of the UseSceneLighting flag.
GetType : function ()
Returns the type of this PolygonStyle.
GetHandle : function ()
Gets the Handle of this PolygonStyle.
GetTextColor : function ()
Gets text Color of this LabelStyle.
GetTextColorWebRGB : function ()
Gets text color of this LabelStyle as web color RGB hex triplet.
GetTextColorWebRGBA : function ()
Gets text color of this LabelStyle as web color RGBA hex quartet.
SetTextColor : function (R,
g,
b,
a)
Sets text Color of this LabelStyle.
SetTextColorWeb : function (webColor)
Deprecated; use SetTextColor instead.
GetType : function ()
Returns the type of this LabelStyle.
GetHandle : function ()
Gets the Handle of this LabelStyle.
GetCloseButtonVisibility : function ()
Gets close button visibility of this BalloonStyle.
SetCloseButtonVisibility : function (bVal)
Sets close button visibility of this BalloonStyle.
HideCloseButton : function ()
Hides close button of this BalloonStyle.
ShowCloseButton : function ()
Shows close button of this BalloonStyle.
IsCloseButtonHidden : function ()
Returns if close button of this BalloonStyle is hidden.
GetBackgroundColor : function ()
Gets background Color of this BalloonStyle.
GetBackgroundColorWebRGB : function ()
Gets background color of this BalloonStyle as web color RGB hex triplet.
GetBackgroundColorWebRGBA : function ()
Gets background color of this BalloonStyle as web color RGBA hex quartet.
SetBackgroundColor : function (R,
g,
b,
a)
Sets background Color of this BalloonStyle.
GetOutlineColor : function ()
Gets outline Color of this BalloonStyle.
GetOutlineColorWebRGB : function ()
Gets outline color of this BalloonStyle as web color RGB hex triplet.
GetOutlineColorWebRGBA : function ()
Gets outline color of this BalloonStyle as web color RGBA hex quartet.
SetOutlineColor : function (R,
g,
b,
a)
Sets outline Color of this BalloonStyle.
GetType : function ()
Returns the type of this BalloonStyle.
GetHandle : function ()
Gets the Handle of this BalloonStyle.
Controls the appearance of a Placemark that has a ModelGeometry object as its geometry property.
Contains information describing the cause of an error.
Represents the eye through which we see the scene.
An abstract class; provides type and handle properties.
An abtract class; provides visibility functionality.
this.CreatePlacemark = function (name,
content,
geom,
styleSet,
infoUrl,
interactive)
Creates a Placemark.
This section documents how GermaniumWeb determines Placemark appearance.
this.AddPlacemark = function (placemark)
Adds the specified Placemark to the scene.
this.GetPlacemarkByIndex = function (index)
Gets the Placemark in the scene with the specified index.
this.GetPlacemarkByHandle = function (handle)
Gets the Placemark in the scene with the specified handle.
this.RemovePlacemark = function (placemark)
Removes the specified Placemark from the scene.
this.RemoveAllPlacemarks = function ()
Removes all Placemarks from the scene.
An abstract class.
this.CreatePointGeometry = function (X,
y,
z)
Creates a PointGeometry (contains location of a Placemark).
this.CreateLineStringGeometry = function ()
Creates a LineStringGeometry.
this.CreatePolygonGeometry = function (X,
y,
z)
Creates a PolygonGeometry.
this.CreateModelGeometry = function (url,
pos,
ort,
scale)
Creates a ModelGeometry.
Enumeration of normal vector directions for PolygonGeometry.
Contains the name and properties of an event that has occurred.
Types of file loading events
this.SetDocumentBase = function (inString)
Sets the document base URL to resolve relative paths.
Controls which origin the ModelGeometry will use as its origin in the scene.
this.CreateStyleSet = function (inGeomStyle,
inLabelStyle,
inBalloonStyle)
Creates a StyleSet (contains style of a Placemark by default).
this.CreateArrowStyle = function (color,
thickness,
width,
headLength,
tailLength,
headStyle,
tailStyle)
Creates an ArrowStyle (controls visual appearance of a Placemark).
this.CreateDiamondStyle = function (color,
width,
upperHeight,
lowerHeight)
Creates a DiamondStyle (controls visual appearance of a Placemark).
this.CreateIconStyle = function (image,
hotspotX,
hotspotY)
Creates an IconStyle (controls visual appearance of a Placemark).
this.CreateLineStyle = function (color,
pattern,
patternScale,
width,
animationMode)
Creates a LineStyle (controls visual appearance of a Placemark).
this.CreateModelStyle = function (useLoadingIcon)
Creates an ModelStyle (controls visual appearance of a Placemark).
this.CreatePolygonStyle = function (fillColor,
fillMode,
outlineColor,
outlineWidth)
Creates a PolygonStyle (controls visual appearance of a Placemark).
Controls line pattern of a LineStyle or a PolygonStyle.
Controls how line pattern is animated.
Controls how a PolygonStyle is shown in the scene.
this.CreateLabelStyle = function (color)
Creates a LabelStyle (controls visual appearance of a Placemark’s text label).
this.CreateBalloonStyle = function (bShowCloseButton,
bgColor,
outlineColor)
Creates a BalloonStyle (controls visual appearance of a Placemark’s callout balloon).