IPolycurve3D Interface

Provides access to members that define operations common to polycurves with Zs.

Description

Provides methods allowing one to add vertices where they do not already exist (Densify), remove existing vertices based on the Douglas-Poiker algorithm (Generalize), and remove existing vertices based on a tolerance obtained from the system units of the geometry’s spatial reference or bounding box (Weed). In contrast to IPolycurve, Z values are taken into account when performing Densify, Generalize, and Weed operations.

Members

Name Description
Method Densify3D Converts this Polycurve into a piecewise linear approximation of itself.
Method Generalize3D Generalizes this polycurve using the Douglas-Peucker algorithm.
Method Weed3D Generalizes using a small tolerance based upon either the system units of the geometry's spatial reference, or the geometry's bounding box.

IPolycurve3D.Densify3D Method

Converts this Polycurve into a piecewise linear approximation of itself.

Public Sub Densify3D ( _
    ByVal maxSegmentLength As Double, _
    ByVal maxDeviation As Double _
)
public void Densify3D (
    double maxSegmentLength,
    double maxDeviation
);

Description

Converts Polycurve into a Polycurve composed of Line segments with 3D length maxSegmentLength (or less) that are within maxDeviation of the original polycurve. If maxDeviation = 0, maxDeviation is ignored and Line segments with length maxSegmentLength are constructed with vertices laying on the original curve. All of the segments in the final polyline will be 3D Lines.

public static void Densify3D()

          {

                 const double DensifyMaxSegmentLength = 2.43; 

                   const double DensifyMaxDeviation = 2;

    

                 IGeometry  polylineGeometry = GetPolylineGeometry();

 



                 IPolycurve3D polycurve3D = polylineGeometry as IPolycurve3D;



                 polycurve3D.Densify3D(DensifyMaxSegmentLength, DensifyMaxDeviation);



         }

IPolycurve3D.Generalize3D Method

Generalizes this polycurve using the Douglas-Peucker algorithm.

Public Sub Generalize3D ( _
    ByVal maxAllowableOffset As Double _
)
public void Generalize3D (
    double maxAllowableOffset
);

Description

Generalizes each part of a Polycurve into a generalized collection of Line segments. Generalize3D performs a Douglas-Peucker Generalization algorithm, extended to operate in 3D space, with a specified maximum offset tolerance, given in 3D, as input. For Line segments, the generalized output is a subset of the original input vertices. For non-linear segments, the generalized output contains points along all parts of the curve, not necessarily only the vertices.

public static void Generalize3D()

          {

                 const double GeneralizeMaxAllowableOffset = 2.229; 

    

                 IGeometry  polylineGeometry = GetPolylineGeometry();

 



                 IPolycurve3D polycurve3D = polylineGeometry as IPolycurve3D;



                 polycurve3D.Generalize3D(GeneralizeMaxAllowableOffset);

   

                ITopologicalOperator  topologicalOperator = polylineGeometry as ITopologicalOperator;

 

                topologicalOperator.Simplify();

         }

IPolycurve3D.Weed3D Method

Generalizes using a small tolerance based upon either the system units of the geometry's spatial reference, or the geometry's bounding box.

Public Sub Weed3D ( _
    ByVal maxAllowableOffsetFactor As Double _
)
public void Weed3D (
    double maxAllowableOffsetFactor
);

Description

Weed generalizes each part of a Polycurve into a generalized collection of z aware Line segments. Weed performs a Douglas-Poiker Generalization algorithm, extended to operate in 3D space, with a specified multiple of the internal tolerance given as input. For Line segments, the Generalized output is a subset of the original input vertices. For non-Linear segments, the Generalized output contains points along all parts of the curve, not necessarily only the vertices.

public static void Weed3D()

          {

                 const double WeedMaxAllowableOffset = 64129865400; 

    

                 IGeometry  polylineGeometry = GetPolylineGeometry();

 



                 IPolycurve3D polycurve3D = polylineGeometry as IPolycurve3D;



                 polycurve3D.Weed3D(WeedMaxAllowableOffset);

   

                ITopologicalOperator  topologicalOperator = polylineGeometry as ITopologicalOperator;

 

                topologicalOperator.Simplify();

         }

Classes that implement IPolycurve3D

Classes Description
Polygon A collection of rings ordered by their containment relationship; optionally has measure, height and ID attributes.
Polyline An ordered collection of paths; optionally has measure, height and ID attributes.

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