Show / Hide Table of Contents

Method Generalize

Generalize(Geometry, Double, Boolean)

Generalizes the given geometry by removing vertices based on the Douglas-Poiker algorithm.

Declaration
public static Geometry Generalize(this Geometry geometry, double maxDeviation, bool removeDegenerateParts)
Parameters
Type Name Description
Geometry geometry

The geometry to be generalized.

System.Double maxDeviation

The maximum distance that the generalized geometry can deviate from the original, in the same units as the geometry's spatial reference system.

System.Boolean removeDegenerateParts

When true, the degenerate parts of the geometry are removed from the output (may be undesired for drawing).

Returns
Type Description
Geometry

A Geometry that represents the generalization of the input geometry.

Remarks

Geometry is generalized by removing vertices based on the Douglas-Poiker algorithm. MapPoint and Multipoint geometries are left unchanged. Envelope is converted to a Polygon and then generalized. Supports true curves as input, producing a densified curve as output where applicable.

Applies to

Platforms and versions
TargetVersions
.NET Standard 2.0100.3 - 200.7
.NET100.13 - 200.7
.NET Windows100.13 - 200.7
.NET Android200.0 - 200.7
.NET iOS200.0 - 200.7
.NET Framework100.0 - 200.7
Xamarin.Android100.0 - 100.15
Xamarin.iOS100.0 - 100.15
UWP100.0 - 200.7
Relevant samples
Densify and generalize: A multipart geometry can be densified by adding interpolated points at regular intervals. Generalizing multipart geometry simplifies it while preserving its general shape. Densifying a multipart geometry adds more vertices at regular intervals.
In This Article
Back to top Copyright © 2022 Esri.