|
Aleph-w 3.0
A C++ Library for Data Structures and Algorithms
|
Demonstrates Douglas-Peucker and Visvalingam-Whyatt simplification with TikZ output. More...
#include <tikzgeom_algorithms.H>#include <cassert>#include <cmath>#include <random>#include <iostream>#include <fstream>Go to the source code of this file.
Functions | |
| static Polygon | make_noisy_circle (size_t n, double radius, double noise, unsigned seed=42) |
| int | main () |
Demonstrates Douglas-Peucker and Visvalingam-Whyatt simplification with TikZ output.
Definition in file polygon_simplification_example.cc.
| int main | ( | ) |
Definition at line 62 of file polygon_simplification_example.cc.
References Aleph::divide_and_conquer_partition_dp(), Aleph::Tikz_Plane::draw(), Aleph::GeomPolygonUtils::extract_vertices(), make_noisy_circle(), Aleph::put_simplification_result(), and Aleph::DouglasPeuckerSimplification::simplify_polygon().
|
static |
Definition at line 45 of file polygon_simplification_example.cc.
References Aleph::Polygon::add_vertex(), Aleph::Polygon::close(), cos(), Aleph::divide_and_conquer_partition_dp(), r, rng, seed, and sin().
Referenced by main().