Distance composite scene symbol

View inWPFUWPFormsiOSAndroid
View on GitHub

Change a graphic's symbol based on the camera's proximity to it.

Image of distance composite scene symbol

Use case

When showing dense datasets, it is beneficial to reduce the detail of individual points when zooming out to avoid visual clutter and to avoid data points overlapping and obscuring each other.

How to use the sample

The sample starts looking at a plane. Zoom out from the plane to see it turn into a cone. Keeping zooming out and it will turn into a point.

How it works

  1. Create a GraphicsOverlay object and add it to a SceneView object.
  2. Create a DistanceCompositeSceneSymbol object.
  3. Create DistanceSymbolRange objects specifying a Symbol and the min and max distance within which the symbol should be visible.
  4. Add the ranges to the range collection of the distance composite scene symbol.
  5. Create a Graphic object with the distance composite scene symbol at a location and add it to the graphics overlay.

Relevant API

  • DistanceCompositeSceneSymbol
  • Range
  • RangeCollection

Tags

3D, data, graphic, range, symbol

Sample Code

UseDistanceCompositeSym.xamlUseDistanceCompositeSym.xaml.cs
          
1
2
3
4
5
6
7
8
9
10
<UserControl
    x:Class="ArcGISRuntime.UWP.Samples.UseDistanceCompositeSym.UseDistanceCompositeSym"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:esriUI="using:Esri.ArcGISRuntime.UI.Controls">

    <Grid>
        <esriUI:SceneView x:Name="MySceneView"/>
    </Grid>
</UserControl>

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.