You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/MAUI/Maui.Samples/Samples/Analysis/ShowExploratoryLineOfSightBetweenGeoelements/ShowExploratoryLineOfSightBetweenGeoelements.xaml
Copy file name to clipboardExpand all lines: src/MAUI/Maui.Samples/Samples/Analysis/ShowExploratoryLineOfSightBetweenGeoelements/ShowExploratoryLineOfSightBetweenGeoelements.xaml.cs
Copy file name to clipboardExpand all lines: src/MAUI/Maui.Samples/Samples/Analysis/ShowExploratoryLineOfSightBetweenGeoelements/readme.md
+10-8Lines changed: 10 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,26 +1,28 @@
1
-
# Line of sight (geoelement)
1
+
# Show exploratory line of sight between geoelements
2
2
3
-
Show a line of sight between two moving objects.
3
+
Show an exploratory line of sight between two moving objects.
4
4
5
-

5
+

6
6
7
7
## Use case
8
8
9
-
A line of sight between `GeoElement`s (i.e. observer and target) will not remain constant whilst one or both are on the move.
9
+
An exploratory line of sight between `GeoElement`s (i.e. observer and target) will not remain constant whilst one or both are on the move.
10
10
11
11
An `ExploratoryGeoElementLineOfSight` is therefore useful in cases where visibility between two `GeoElement`s requires monitoring over a period of time in a partially obstructed field of view
12
12
(such as buildings in a city).
13
13
14
+
Note: This analysis is a form of "exploratory analysis", which means the results are calculated on the current scale of the data, and the results are generated very quickly but not persisted.
15
+
14
16
## How to use the sample
15
17
16
-
A line of sight will display between a point on the Empire State Building (observer) and a taxi (target).
17
-
The taxi will drive around a block and the line of sight should automatically update.
18
+
An exploratory line of sight will display between a point on the Empire State Building (observer) and a taxi (target).
19
+
The taxi will drive around a block and the exploratory line of sight should automatically update.
18
20
The taxi will be highlighted when it is visible. You can change the observer height with the slider to see how it affects the target's visibility.
19
21
20
22
## How it works
21
23
22
24
1. Instantiate an `AnalysisOverlay` and add it to the `SceneView`'s analysis overlays collection.
23
-
2. Instantiate an `ExploratoryGeoElementLineOfSight`, passing in observer and target `GeoElement`s (features or graphics). Add the line of sight to the analysis overlay's analyses collection.
25
+
2. Instantiate an `ExploratoryGeoElementLineOfSight`, passing in observer and target `GeoElement`s (features or graphics). Add the exploratory line of sight to the analysis overlay's analyses collection.
24
26
3. To get the target visibility when it changes, react to the target visibility changing on the `ExploratoryGeoElementLineOfSight` instance.
25
27
26
28
## Relevant API
@@ -37,4 +39,4 @@ This sample downloads the following items from ArcGIS Online automatically:
37
39
38
40
## Tags
39
41
40
-
3D, line of sight, visibility, visibility analysis
42
+
3D, exploratory line of sight, visibility, visibility analysis
Copy file name to clipboardExpand all lines: src/MAUI/Maui.Samples/Samples/Analysis/ShowExploratoryLineOfSightBetweenPoints/ShowExploratoryLineOfSightBetweenPoints.xaml
Copy file name to clipboardExpand all lines: src/MAUI/Maui.Samples/Samples/Analysis/ShowExploratoryLineOfSightBetweenPoints/ShowExploratoryLineOfSightBetweenPoints.xaml.cs
name:"Show exploratory line of sight between points",
20
20
category:"Analysis",
21
-
description:"Perform a line of sight analysis between two points in real time.",
22
-
instructions:"Tap to place the starting point for the line. Tap again to place the end point.",
23
-
tags:new[]{"3D","line of sight","visibility","visibility analysis"})]
24
-
publicpartialclassLineOfSightLocation:ContentPage
21
+
description:"Perform an exploratory line of sight analysis between two points in real time.",
22
+
instructions:"The sample loads with a preset observer and target location, linked by a colored line. A red segment on the line means the view between observer and target is obstructed, whereas green means the view is unobstructed.",
23
+
tags:new[]{"3D","exploratory line of sight","visibility","visibility analysis"})]
Perform an exploratory line of sight analysis between two points in real time.
4
+
5
+

6
+
7
+
## Use case
8
+
9
+
An exploratory line of sight analysis can be used to assess whether a view is obstructed between an observer and a target. Obstructing features could either be natural, like topography, or man-made, like buildings. Consider an events planning company wanting to commemorate a national event by lighting sequential beacons across hill summits or roof tops. To guarantee a successful event, ensuring an unobstructed line of sight between neighboring beacons would allow each beacon to be activated as intended.
10
+
11
+
Note: This analysis is a form of "exploratory analysis", which means the results are calculated on the current scale of the data, and the results are generated very quickly but not persisted. If persisted analysis performed at the full resolution of the data is required, consider using a `LineOfSightFunction` to perform a line of sight calculation instead.
12
+
13
+
## How to use the sample
14
+
15
+
The sample loads with a preset observer and target location, linked by a colored line. A red segment on the line means the view between observer and target is obstructed, whereas green means the view is unobstructed.
16
+
17
+
Tap to place the starting (observer) point for the line. Tap again to place the end (target) point.
18
+
19
+
## How it works
20
+
21
+
1. Create an `AnalysisOverlay` and add it to the scene view.
22
+
2. Create an `ExploratoryLocationLineOfSight` with initial observer and target locations and add it to the analysis overlay.
23
+
3. Listen for taps on the scene.
24
+
4. Update the target and observer positions by updating `ExploratoryLocationLineOfSight.ObserverLocation` and `ExploratoryLocationLineOfSight.TargetLocation`.
25
+
26
+
## Relevant API
27
+
28
+
* AnalysisOverlay
29
+
* ExploratoryLocationLineOfSight
30
+
* SceneView
31
+
32
+
## Tags
33
+
34
+
3D, exploratory line of sight, visibility, visibility analysis
0 commit comments