ArcGIS Pro 3.2 API Reference Guide
ArcGIS.Core.Data.Analyst3D Namespace / SurfaceConstraint Class
Members Example

In This Topic
    SurfaceConstraint Class
    In This Topic
    Represents a surface constraint in a LAS dataset. See GetSurfaceConstraints.
    Syntax
    public sealed class SurfaceConstraint 
    Public NotInheritable Class SurfaceConstraint 
    Remarks
    Surface constraints are features whose geometry capture or define the characteristics of the surface. Breaklines, water polygons, or area clipping boundaries are all examples of surface constraints. Surface constraints can be feature classes or shapefiles.
    Example
    Get Surface Constraint information from a LAS Dataset
    var constraintCount = lasDataset.GetSurfaceConstraintCount();
    IReadOnlyList<ArcGIS.Core.Data.Analyst3D.SurfaceConstraint> constraints = lasDataset.GetSurfaceConstraints();
    foreach (var constraint in constraints)
    {
      var dsName = constraint.DataSourceName;
      var wksPath = constraint.WorkspacePath;
      var heightField = constraint.HeightField;
      var surfaceType = constraint.SurfaceType;
    }
    Active Surface Constraints
    var activeSurfaceConstraints = lasDatasetLayer.GetActiveSurfaceConstraints();
    
    // clear all surface constraints (i.e. none are active)
    lasDatasetLayer.SetActiveSurfaceConstraints(null);
    
    // set all surface constraints active
    using (var lasDataset = lasDatasetLayer.GetLasDataset())
    {
      var surfaceConstraints = lasDataset.GetSurfaceConstraints();
      var names = surfaceConstraints.Select(sc => sc.DataSourceName).ToList();
      lasDatasetLayer.SetActiveSurfaceConstraints(names);
    }
    Inheritance Hierarchy

    System.Object
       ArcGIS.Core.Data.Analyst3D.SurfaceConstraint

    Requirements

    Target Platforms: Windows 11, Windows 10

    ArcGIS Pro version: 3.2 or higher.
    See Also