Simpli

Powered by Mason melos coverage

Polyline simplification algorithms, made simple! Sporting exciting algorithms such as ✨Ramer-Douglas-Peucker✨ and ✨Visvalingam✨.

Installation 💻

❗ In order to start using Simpli you must have the Dart SDK installed on your machine.

Install via dart pub add:

dart pub add simpli

Usage 🚀

import 'package:simpli/simpli.dart';

void main() {
  final points = [
    Point(0, 0),
    Point(1, 1),
    Point(2, 0),
    Point(3, 3),
    Point(4, 0),
  ];

  final rdpSimplified = Simpli.ramerDouglasPeucker(points, pixelTolerance: 50.0);
  final visvalingamSimplified = Simpli.visvalingam(points, pixelTolerance: 50.0);

  print(simplifiedPoints);
  print(visvalingamSimplified);
}

Libraries

simpli
Polyline simplification algorithms, made simple! Sporting Ramer-Douglas-Peucker and Visvalingam