Public Function GetAvailableClassCodesAndLabels() As Dictionary(Of Integer,String)
public Dictionary<int,string> GetAvailableClassCodesAndLabels()
Return Value
Dictionary {System.Int32, System.String}
Public Function GetAvailableClassCodesAndLabels() As Dictionary(Of Integer,String)
public Dictionary<int,string> GetAvailableClassCodesAndLabels()
| Exception | Description |
|---|---|
| ArcGIS.Core.CalledOnWrongThreadException | This method or property must be called within the lambda passed to QueuedTask.Run. |
{
// Note: call within QueuedTask.Run()
{
Dictionary<int, string> classCodesAndLabels =
pointCloudSceneLayer.GetAvailableClassCodesAndLabels();
}
}
{
// Note: call within QueuedTask.Run()
{
//Retrieve the available classification codes
var dict = pointCloudSceneLayer.GetAvailableClassCodesAndLabels();
//Filter out low noise and unclassified (7 and 1 respectively)
//consult https://pro.arcgis.com/en/pro-app/help/data/las-dataset/storing-lidar-data.htm
var filterDef = new PointCloudFilterDefinition()
{
ClassCodes = dict.Keys.Where(c => c != 7 && c != 1).ToList(),
ReturnValues = new List<PointCloudReturnType> {
PointCloudReturnType.FirstOfMany }
};
//apply the filter
pointCloudSceneLayer.SetFilters(filterDef.ToCIM());
}
}
Target Platforms: Windows 11 Home, Pro, Enterprise (64 bit)