Create3DViewshed

Creates a graphical representation of all regions on the terrain and on 3D models and objects that are visible, within a field of view, from a given viewing point.

 

JavaScript

 

CreateViewshed(

       ViewerPosition,

       FieldOfViewX,

       FieldOfViewY,

       Distance,

       ParentGroupID,

       Description)

 

C#

 

I3DViewshed66 Create3DViewshed(

       IPosition66 ViewerPosition,

       double FieldOfViewX,

       double FieldOfViewY,

       double Distance,

       [string ParentGroupID = ""],

       [string Description = ""])

 

C++

 

HRESULT Create3DViewshed(

IPosition66* ViewerPosition,

double FieldOfViewX,

double FieldOfViewY,

double Distance

BSTR ParentGroupID,

BSTR Description,

I3DViewshed66** pI3DViewshed66)

Parameters

ViewerPosition

An IPosition66 representing the viewing point position, defined by its coordinates in the 3D World.

FieldOfViewX

The horizontal angle limits of the viewshed. Values are in degrees from 0 to 120. For a spherical 3D viewshed, the value is 360.

FieldOfViewY

The vertical angle limits of the viewshed. Values are in degrees from 0 to 120. For a spherical 3D viewshed, the value is 360.

Distance

Length, in meters, of the viewshed analysis from the viewer position.

ParentGroupID

The Project Tree group in which the model is created. If it is set to an empty string, the object is created under the root. You can obtain the GroupID by one of the following methods:

·          Create the group using IProjectTree66.CreateGroup.

·          Find the group, if you know the name, using IProjectTree66.FindItem.

·          Traverse the Tree using IProjectTree66 methods such as GetNextItem, until you come to the desired GroupID.

Description

The name of the viewshed object as it appears in the Project Tree. If an empty string is passed to this parameter, TerraExplorer assigns it a unique name.

Return Value

pI3DViewshed66

An I3DViewshed66 representing the newly created 3D viewshed object.

Exceptions

See: HRESULT Return Values for a list of possible values returned by the HRESULT.