IMeshLayer80

This interface provides access to unified, stream optimized 3D Mesh Layer (3DML) databases. 3DML databases are created in TerraExplorer or PhotoMesh by merging layers of 3D mesh city models (generated by PhotoMesh), together with classification layers, and other model layers. Simple 3DMLs can also be created in TerraExplorer from point layers with individually referenced 3D model files.

 

 

Properties

 

BBox

An IBBox3D80 representing the bounding box that designates the section of the 3DML layer to load.

CoordinateSystem

An ICoordinateSystem80 representing the layer's coordinate system.

DisplayStyle

Gets and sets the mesh model display style. The mesh model can include a wireframe and be textured or solid color.

FeatureLayers

An I3DMLFeatureLayers80 that returns the number of feature layers in the 3DML dataset and provides the index of each layer.

GroundObject

Gets and sets a Boolean that determines whether the 3DML object is a ground object.

ID

Gets the ID of the 3DML. (Inherited from ITerraExplorerObject80)

MeshGroundOffset

Gets and sets the offset from the mesh ground for drawing and placement of “on terrain” and “relative to 3DML“ objects.

ObjectType

Gets an enum that identifies the type of the object. (Inherited from ITerraExplorerObject80)

Oversampling

Gets and sets the mesh layer’s Level of Detail (LOD).

Path

Gets and sets the full path of the 3DML file.

Position

An IPosition80 representing the 3DML’s position on the terrain.

ReplaceTerrainWithMesh

Gets and sets a Boolean that determines whether the mesh layer replaces the terrain imagery and elevation in the area of the 3DML.

ReprojectElevation

Gets and sets a Boolean that determines if the layer’s elevation coordinates are reprojected from the layer’s coordinate system to the terrain’s coordinate system.

SaveInFlyFile

Gets and sets a Boolean that determines whether the 3DML is saved in the Fly file. (Inherited from ITerraExplorerObject80)

ScaleFactor

Gets and sets the scale factor for the mesh layer.

ScaleX

Gets and sets the value by which to scale the mesh layer on its x axis.

ScaleY

Gets and sets the value by which to scale the mesh layer on its y axis.

ScaleZ

Gets and sets the value by which to scale the mesh layer on its z axis.

TreeItem

An ITreeItem80 representing details about the representation of the 3DML in the Project Tree.

Visibility

An IVisibility80 representing the visibility of the layer at different distances.

 

Methods

 

GetClientData

Gets an array of text strings assigned to each object global namespace. (Inherited from ITerraExplorerObject80)

GetParam

Reserved. Currently not used. (Inherited from ITerraExplorerObject80)

Refresh

Refreshes the layer.

SetClientData

Sets an array of text strings assigned to each object global namespace. (Inherited from ITerraExplorerObject80)

SetParam

Reserved. Currently not used. (Inherited from ITerraExplorerObject80)

 

DisplayStyle

Gets and sets the mesh model display style:

§   MLDM_NORMAL = 0 – Textured model

§   MLDM_XRAY = 2 - Semi-transparent model, enabling you to see through all model walls.

§   MLDM_SOLID = 3 – Solid color

Any of these modes can be combined with the wireframe mode:

§   MLDM_ADD_WIRE = 32768 – Add wireframe

 

JavaScript

 

DisplayStyle

 

C#

 

string DisplayStyle { get; set; }

 

C++

 

HRESULT DisplayStyle ([out, retval] MeshLayerDisplayStyle * pVal)

HRESULT DisplayStyle ([in] MeshLayerDisplayStyle pVal)

 

GroundObject

Gets and sets a Boolean that determines whether the object is a ground object. For more information about ground objects, see the TerraExplorer User Manual.

 

JavaScript

 

 

 

GroundObject

 

C#

 

 

 

bool GroundObject { get; set; }

 

C++

 

 

 

HRESULT GroundObject([out, retval] VARIANT_BOOL* pVal)

HRESULT GroundObject([in] VARIANT_BOOL pVal)

MeshGroundOffset

Gets and sets the offset from the mesh ground for drawing and placement of “on terrain” and “relative to 3DML“ objects.

 

JavaScript

 

MeshGroundOffset

 

C#

 

string MeshGroundOffset { get; set; }

 

C++

 

HRESULT MeshGroundOffset ([out, retval] double* pVal)

HRESULT MeshGroundOffset ([in] double pVal)

 

Oversampling

Gets and sets the mesh layer’s Level of Detail (LOD). When set to Normal, TerraExplorer determines the optimal quality to performance balance based on the current view. This parameter can be any of the following values:

§   OVERSAMPLING_LOW = 75

§   OVERSAMPLING_NORMAL = 100

§   OVERSAMPLING_HIGH = 125

§   OVERSAMPLING_BEST = 150

 

JavaScript

 

Oversampling

 

C#

 

string Oversampling { get; set; }

 

C++

 

HRESULT Oversampling ([out, retval] OVERSAMPLING* pVal)

HRESULT Oversampling ([in] OVERSAMPLING pVal)

 

Path

Gets and sets the full path or SkylineGlobe Server URL of the 3DML file. The SGS URL should be in the following format: http://SGServerAddress/SG/[Site]/streamer.ashx?layer=[Name].[ID]

E.g., http://www.skylineglobe.com/SG/default/streamer.ashx?layer=Auburn_Build_8_full_PM75Patch.2463411

 

JavaScript

 

Path

 

C#

 

string Path { get; set; }

 

C++

 

HRESULT Path( [out, retval] BSTR* pVal)

HRESULT Path( [in] BSTR pVal)

Refresh

Refreshes the layer.

 

JavaScript

 

Refresh

 

C#

 

void Refresh()

 

C++

 

HRESULT Refresh()

ReplaceTerrainWithMesh

This property gets and sets an enum that determines whether terrain imagery and elevation in the mesh area is replaced with the 3DML’s ground layer (created in 3DML from PhotoMesh) or with the mesh’s lower resolution data (Simplified Mesh), or not replaced at all. The following are the possible values:

§   REPLACE_TERRAIN_NONE = 0

§   REPLACE_TERRAIN_WITH_3DML_GROUND_LAYER = 1

§   REPLACE_TERRAIN_WITH_SIMPLIFIED_MESH = 2

 

JavaScript

 

ReplaceTerrainWithMesh

 

C#

 

ReplaceTerrainMeshType ReplaceTerrainWithMesh { get; set; }

 

C++

 

HRESULT ReplaceTerrainWithMesh ( [out, retval] ReplaceTerrainMeshType* pVal)

HRESULT ReplaceTerrainWithMesh ( [in] ReplaceTerrainMeshType pVal)

ReprojectElevation

Gets and sets a Boolean that determines if the layer’s elevation coordinates are reprojected from the layer’s coordinate system to the terrain’s coordinate system. This property applies only to mesh layers whose Position.AltitudeType is set to ATC_Terrain_Absolute = 3. Geocentric layers are always reprojected even if this property is set to false.

Note:    Changes are applied only following a call to Refresh().

 

JavaScript

 

ReprojectElevation

 

C#

 

bool ReprojectElevation { get; set; }

 

C++

 

HRESULT ReprojectElevation([out, retval] VARIANT_BOOL* pVal)

HRESULT ReprojectElevation ([in] VARIANT_BOOL pVal)

 

ScaleFactor

Gets and sets the scale factor for the mesh layer. This property scales the model in all three axes, maintaining the model’s original aspect ratio.

 

JavaScript

 

ScaleFactor

 

C#

 

double ScaleFactor { get; set; }

 

C++

 

HRESULT ScaleFactor([out, retval] double* pVal)

HRESULT ScaleFactor([in] double pVal)

ScaleX

Gets and sets the value by which to scale the mesh layer on the X axis. The mesh layer can be scaled independently in each of the three axes. The actual X value of the layer in the 3D World is the x value of the layer in its internal coordinate system multiplied by the ScaleX value. (i.e., if the mesh layer has an X value of 5 units and the ScaleX is set to 10 meters per pixel, the x value of the object in the 3D World is 50 meters.)

Note:    If you want to scale the mesh layer in all three axes, maintaining the model’s aspect ratio, use the ScaleFactor property.

 

JavaScript

 

ScaleX

 

C#

 

double ScaleX { get; set; }

 

C++

 

HRESULT ScaleX([out, retval] double* pVal)

HRESULT ScaleX([in] double pVal)

ScaleY

Gets and sets the value by which to scale the mesh layer on the Y axis. The mesh layer can be scaled independently in each of the three axes. The actual Y value of the layer in the 3D World is the y value of the layer in its internal coordinate system multiplied by the ScaleY value. (i.e., if the mesh layer has a Y value of 5 units and the ScaleY is set to 10 meters per pixel, the y value of the object in the 3D World is 50 meters.)

Note:    If you want to scale the mesh layer in all three axes, maintaining the model’s aspect ratio, use the ScaleFactor property.

 

JavaScript

 

ScaleY

 

C#

 

double ScaleY { get; set; }

 

C++

 

HRESULT ScaleY([out, retval] double* pVal)

HRESULT ScaleY([in] double pVal)

ScaleZ

Gets and sets the value by which to scale the mesh layer on the Z axis. The mesh layer can be scaled independently in each of the three axes. The actual height of the layer in the 3D World is the height of the mesh layer in its internal coordinate system multiplied by the ScaleZ value. (i.e., if the mesh layer has a height of 5 units and the ScaleZ is set to 10 meters per pixel, the height of the object in the 3D World is 50 meters.)

Note:    If you want to scale the mesh layer in all three axes, maintaining the model’s aspect ratio, use the ScaleFactor property.

 

JavaScript

 

ScaleZ

 

C#

 

double ScaleZ { get; set; }

 

C++

 

HRESULT ScaleZ([out, retval] double* pVal)

HRESULT ScaleZ([in] double pVal)