All Cadcorp SIS API Methods

CreateViewshed Method

Description

Create a Viewshed on a grid in a named list.

Syntax

Visual Basic
Public Function CreateViewshed( _
   ByVal list As String, _
   ByVal x As Double, _
   ByVal y As Double, _
   ByVal z As Double, _
   ByVal r As Double, _
   ByVal bQZone As Long _
) As Integer

Parameters

list
The named list containing a grid item.
 
x
The x coordinate of the eye position from which the grid is viewed to create the viewshed.

y
The y coordinate of the eye position from which the grid is viewed to create the viewshed.
 
z
The z coordinate of the eye position from which the grid is viewed to create the viewshed.
 
r
The maximum distance from the eye position for which the viewshed will be calculated.
 
bQZone
0  create the viewshed as a grid item
1 create the viewshed as a QZone item

Remarks

If the list contains more than one grid only the first will be used. The z value is absolute, i.e. not a relative distance. The resolution of the resulting QZone depends on the size of the grid cells.

Available: GEO OD SISpy

Group:

Example

            sis.CreateViewshed("MyGrid", xpos, ypos, zpos+10, 4000, 1)

Creates a QZone to represent the viewshed of the grid in the list MyGrid viewed from a position 10m above x, y, z with a maximum view radius of 4000m.