densifyGeodetic static method

Geometry densifyGeodetic(
  1. {required Geometry geometry,
  2. required double maxSegmentLength,
  3. LinearUnit? lengthUnit,
  4. required GeodeticCurveType curveType}
)

Densifies the input geometry by creating additional vertices along the geometry, using a geodetic curve.

Parameters:

  • geometry — A geometry to densify.
  • maxSegmentLength — The maximum distance between vertices when the input geometry is densified, in the given linear units.
  • lengthUnit — The unit of measure for the maximum segment length. If null, meters are assumed.
  • curveType — The type of curve to calculate.

Return Value: The geodetic densified geometry.

Implementation

static Geometry densifyGeodetic(
    {required Geometry geometry,
    required double maxSegmentLength,
    LinearUnit? lengthUnit,
    required GeodeticCurveType curveType}) {
  _initializeArcGISEnvironmentIfNeeded();
  final objectHandle = _withThrowingErrorHandler((errorHandler) {
    return runtimecore.RT_GeometryEngine_densifyGeodetic(
        geometry._handle,
        maxSegmentLength,
        lengthUnit?._handle ?? ffi.nullptr,
        curveType.coreValue,
        errorHandler);
  });
  return Geometry._fromHandle(objectHandle)!;
}