ArcGIS Runtime SDK for iOS: AGSGeoElementLineOfSight Class Reference
ArcGIS Runtime SDK for iOS  100.15
AGSGeoElementLineOfSight Class Reference

Description

Analysis of visibility along a line between two geo-elements.

Instances of this class represent an analysis object that evaluates visibility along a line defined by observer and target geo-element objects.

The result of the analysis is a line between the observer and the target geo-element (each using Point geometry). Visible and obstructed portions of the line are displayed with unique colors (green and red by default). The observer and/or target may be moving, in which case visibility will be dynamically updated.

Note
The geo-elements must have a point geometry

License Restrictions:
This feature requires a Standard license for production deployment. No license required in Developer mode for testing.

Since
100.2
Inheritance diagram for AGSGeoElementLineOfSight:
AGSLineOfSight AGSAnalysis AGSObject

Instance Methods

(instancetype) - initWithObserverGeoElement:targetGeoElement:
 

Class Methods

(instancetype) + lineOfSightWithObserverGeoElement:targetGeoElement:
 
(CGFloat) + lineWidth
 
(AGSColor *) + obstructedColor
 
(void) + setLineWidth:
 
(void) + setObstructedColor:
 
(void) + setVisibleColor:
 
(AGSColor *) + visibleColor
 

Properties

id< AGSGeoElementobserverGeoElement
 
double observerOffsetX
 
double observerOffsetY
 
double observerOffsetZ
 
id< AGSGeoElementtargetGeoElement
 
double targetOffsetX
 
double targetOffsetY
 
double targetOffsetZ
 
AGSLineOfSightTargetVisibility targetVisibility
 
BOOL visible
 

Method Documentation

◆ initWithObserverGeoElement:targetGeoElement:

- (instancetype) initWithObserverGeoElement: (id< AGSGeoElement >)  observerGeoElement
targetGeoElement: (id< AGSGeoElement >)  targetGeoElement 

Intialize the analysis with the provided observer and target geo-elements. As a result of the analysis, a line is rendered between the observer and target elements with distinct colors representing visible and obstructed segments.

Note
The geo-elements must have a point geometry
Parameters
observerGeoElementdefining the observer's location
targetGeoElementdefining the target's location
Returns
Initialized line of sight analysis
Since
100.2

◆ lineOfSightWithObserverGeoElement:targetGeoElement:

+ (instancetype) lineOfSightWithObserverGeoElement: (id< AGSGeoElement >)  observerGeoElement
targetGeoElement: (id< AGSGeoElement >)  targetGeoElement 

Intialize the analysis with the provided observer and target geo-elements. As a result of the analysis, a line is rendered between the observer and target elements with distinct colors representing visible and obstructed segments.

Note
The geo-elements must have a point geometry
Parameters
observerGeoElementdefining the observer's location
targetGeoElementdefining the target's location
Returns
Initialized line of sight analysis
Since
100.2

◆ lineWidth

+ (CGFloat) lineWidth

The line width used to render analysis results. This setting is applied to all line of sight analyses in the view.

Since
100.2

◆ obstructedColor

+ (AGSColor *) obstructedColor

The color used to render segments that are not visible along the analysis results. Sections of the line between the observer and the target that are obstructed (not visible) are drawn with the specified color. This setting is applied to all line of sight analyses in the view.

Since
100.2

◆ setLineWidth:

+ (void) setLineWidth: (CGFloat)  lineWidth

Sets the line width used to render analysis results. This setting is applied to all line of sight analyses in the view.

Parameters
lineWidthin points
Since
100.2

◆ setObstructedColor:

+ (void) setObstructedColor: (AGSColor *)  obstructedColor

Sets the color used to render segments that are not visible along the analysis results. Sections of the line between the observer and the target that are obstructed (not visible) are drawn with the specified color. This setting is applied to all line of sight analyses in the view.

Parameters
obstructedColorused to render segments that are not visible
Since
100.2

◆ setVisibleColor:

+ (void) setVisibleColor: (AGSColor *)  visibleColor

Sets the color used to render segments that are visible along the analysis results. Sections of the line between the observer and the target that are visible are drawn with the specified color. This setting is applied to all line of sight analyses in the view.

Parameters
visibleColorused to render segments that are visible
Since
100.2

◆ visibleColor

+ (AGSColor *) visibleColor

The color used to render segments that are visible along the analysis results. Sections of the line between the observer and the target that are visible are drawn with the specified color. This setting is applied to all line of sight analyses in the view.

Since
100.2

Property Documentation

◆ observerGeoElement

- (id<AGSGeoElement>) observerGeoElement
readnonatomicstrong

Geo-element defining the observer's location. The observer location is determined by the location of the geo-element plus any defined offsets (in X, Y, or Z). The offset position of the observer relative to the geo-element is always maintained, even when the geo-element moves.

Note
The geo-element must have a point geometry
Since
100.2

◆ observerOffsetX

- (double) observerOffsetX
readwritenonatomicassign

The offset along the X axis relative to the observer geo-element's point location.

Since
100.2

◆ observerOffsetY

- (double) observerOffsetY
readwritenonatomicassign

The offset along the Y axis relative to the observer geo-element's point location.

Since
100.2

◆ observerOffsetZ

- (double) observerOffsetZ
readwritenonatomicassign

The offset along the Z axis relative to the observer geo-element's point location.

Since
100.2

◆ targetGeoElement

- (id<AGSGeoElement>) targetGeoElement
readnonatomicstrong

Geo-element defining the target's location. The target location is determined by the location of the geo-element plus any defined offsets (in X, Y, or Z). The offset position of the target relative to the geo-element is always maintained, even when the geo-element moves.

Note
The geo-element must have a point geometry
Since
100.2

◆ targetOffsetX

- (double) targetOffsetX
readwritenonatomicassign

The offset along the X axis relative to the target geo-element's point location.

Since
100.2

◆ targetOffsetY

- (double) targetOffsetY
readwritenonatomicassign

The offset along the Y axis relative to the target geo-element's point location.

Since
100.2

◆ targetOffsetZ

- (double) targetOffsetZ
readwritenonatomicassign

The offset along the Z axis relative to the target geo-element's point location.

Since
100.2

◆ targetVisibility

- (AGSLineOfSightTargetVisibility) targetVisibility
readnonatomicassigninherited

Indicates state of the target's visbility.

Since
100.2

◆ visible

- (BOOL) visible
readwritenonatomicassigninherited

Indicates whether the results of this analysis should be visible or not. Visibility can be controlled for individual analyses as well as for the analysis overlay that contains them.

Since
100.2