Settings

Allows defining the value of a specified parameter in the Fly file Project Settings. Each parameter is accessed by a unique identification string. This property is exposed in C# and JavaScript in the following ways:

§   In C#, this property is exposed as Settings, e.g.,

SGWorld80.Project.Settings["CopyrightText"] = "My Copyright";

Note:    In older versions of C#, this property is exposed as set_Settings and get_Settings, e.g.,

SGWorld80.Project.set_Settings["CopyrightText"] = "My Copyright";)

§   In JavaScript use:

SGWorld80.Project.Settings("CopyrightText") = "My Copyright";

 

JavaScript

 

Settings(paramName)

 

C#

 

dynamic Settings { get; set; }

 

C++

 

HRESULT Settings(

       [in] BSTR paramName,

       [out, retval] VARIANT* pVal)

HRESULT Settings(

       [in] BSTR paramName,

       [in] VARIANT pVal)

 

The following table describes the supported parameter string values and the respective parameter value options:

 

paramName

[In/Out] Type

pVal

 

General

 

“GenerateLevelsOfDetailFor3DModels”

[in, out] long

Determines whether all loaded models are automatically optimized by conversion to XPL2 upon loading.

 

“DoubleSidedRenderingOf3DModels”

[in, out] long

Determines whether the faces of 3D models are rendered from two sides.

 

Layout

"TerraExplorerWindowSize"

[in, out] safe array of integers

Determines the size of the TerraExplorer window and containers.

To set specific values, pass an array with the following values = [Width, Height, LeftContainerWidth, TopContainerHeight, RightContainerWidth, BottomContainerHeight]

Alternatively, set the value as one of the following:

§   1 – Capture the current layout. It will be saved in the FLY file the next time the project is saved.

§   0 – Restore to default sizes and then capture the layout. It will be saved in the FLY file the next time the project is saved

Note:     In JavaScript, use the VBArray object, E.g.,  

var windowSize = SGWorld.Project.Settings("TerraExplorerWindowSize");

var arr = new VBArray(windowSize).toArray();

Terrain Database

 

"ReprojectElevationDefaultSetting"

[in, out] long

Determines the default Reproject Elevation setting for 3DML, elevation, and feature layers when they are initially loaded into the project. 1 – TerraExplorer reprojects the layer’s elevation values to the terrain’s coordinate system, if the layer includes vertical datum or is a 3DML created in TerraExplorer 7.1 or PhotoMesh 7.4 or higher. 0 – TerraExplorer does not reproject.

Note:    Geocentric layers are always reprojected.

 

Screen Overlay

 

“CopyrightText”

[in, out] BSTR

A string description of the copyright text that appears on the 3D Window.

 

"RemoveSkylineCopyright"

[in, out] long

Determines whether the Skyline copyright text is removed. 1 – removed or 0 – displayed.

 

Environment

 

"FogColor"

[in, out] long

The color of the fog that covers the terrain in hexadecimal form: 0x00bbggrr.

 

"SkyColor"

[in, out] long

The color of the sky in the hexadecimal form: 0x00bbggrr.

 

"VisualRange"

[in, out] double

Distance to the horizon, in meters

 

"FogStart "

[in, out] double

Distance, in meters, at which the fog starts

 

"DisplaySun"

[in, out] long

Determines whether the sun is used as the light source. 1 – displayed or 0 – hidden.

 

"SunAndMoonUseFixedLocalTime "

[in, out] long

Determines whether the currently used date and time value is defined in local time (1) or global date and time (0).

Note:    Changes only take effect after saving and reopening the TerraExplorer project.

 

"SunAndMoonFixedLocalTime"

[in, out] VT_DATE

Date (Javascript) or DateTime (C#) object that represents the currently used local time. SeeTime” for information on valid formats for this parameter.

Note:    Changes only take effect after saving and reopening the TerraExplorer project.

 

"SunAndMoonTime"

[in, out] VT_DATE

Date (Javascript) or DateTime (C#) object that represents the currently used global date and time. SeeTime” for information on valid formats for this parameter.

Note:    Changes only take effect after saving and reopening the TerraExplorer project.

 

"TimeZoneListXML"

[out] BSTR

An XML string that defines the available time zones in the operating system. For example:

<SELECT ID="TimeZoneList" SIZE="XX">

<OPTION VALUE ="Alaska Standard Time">(GMT-09:00) Alaska<OPTION>

. . .

<SELECT>

 

"SunAndMoonTimeZoneDisplayName"

[out] BSTR

A string description of the currently used time zone, e.g., "(GMT-09:00) Alaska". The string corresponds to the value of the OPTION node in the XML returned from "TimeZoneListXML”

 

"SunAndMoonTimeZoneKey"

[in, out] BSTR

A string key of the used time zone, e.g., "Alaska Standard Time". The key can be one of the VALUE attributes of an OPTION node in the XML returned from "TimeZoneListXML.

Note:    Changes only take effect after saving and reopening the TerraExplorer project.

 

Navigation

 

"AltitudeMinimumAltitude"

[in, out] double

Determines the minimum altitude allowed for the plane in meters or feet above ground level.

 

“AltitudeUndergroundSurface”

[in, out] double

Determines the altitude above the terrain database vertical datum base ellipsoid.

 

"AltitudeUndergroundSurface"

[in, out] double

Determines the altitude above the terrain database vertical datum base ellipsoid.

 

"KeyboardAndMouseNavigationSpeed"

[in, out] double

Determines the navigation speed when using the keyboard controls and mouse.

 

“JoystickNavigationSpeed”

[in, out] double

Determines the joystick speed.