This sample demonstrates how to identify geoelements in a scene layer.
How it works
Click on a building in the scene layer to select it. Unselect buildings by clicking away from the buildings.
- Create an AGSArcGISSceneLayer passing in the URL to a scene layer service.
- Use sceneView.touchDelegate to get the screen tap location screenPoint.
- Call sceneView.identifyLayer(_:screenPoint:tolerance:returnPopupsOnly:completion:) to identify features in the scene.
- From the resulting AGSIdentifyLayerResult, get the list of identified AGSGeoElements with result.geoElements.
- Get the first element in the list, checking that it is a feature, and call sceneLayer.select(feature) to select it