Cours de Visualisation d'Information InfoVis Lecture Maps & Voronoï
List of edges at equal distance of 2 pts. ⢠List of ... [Manhattan dist] ... Voronoï word clouds ... d d. [https://people.csail.mit.edu/indyk/6.838-old/handouts/lec8.pdf] ...
Cours de Visualisation d'Information InfoVis Lecture !
Maps & Voronoï diagrams Frédéric Vernier Maître de conférence / Lecturer Univ. Paris Sud
[https://twitter.com/RodBogart]
Outline • Voronoï & Delaunay • Usages • Algorithms • Use case
Voronoï Diagrams & Delaunay triangulation
• Partitioning of a plane • List of non overlapping polygons • List of edges at equal distance of 2 pts • List of points at equal distance of 3 pts • Delaunay triangulation = dual • List of triangles
• Sort all the points according to one direction (ie y) • process point one by one and consider parabolas • equal dist. point & line d • n points => n parabolas d ! !
Beach line & Sweep line Sites/points already processed Beach line = n parabolas Breakpoint Sweep line Direction of the process Sites/points to process
New point event • Sweepline cross a point(site) • Parabola is first just a vertical segment • 2 new break points at the same location • When sweep line moves further away • parabola get wider and 2 breakpoints slides
parabola disappearing event Notice the small hyperbola ?
connected to 3 (sliding) points it now disappears ! a new point found its definitive position in the Voronoï diagram
parabola disappearing • When does it happen ? • very likely between 2 points to process • if we process the next point … it’s too late • Let’s introduce a fake point in the ordered list
3 consecutive points in the beach line make a circle bottom of the circle = WHEN middle parabola disappear
fortune algorithm • Ordered list of points (real sites and fake pt) • Ordered list of parabolas (act. parabola arcs) • use a (balanced) binary tree • leaf = parabola = site • node = intersection = point
2 Use case • 36000 towns of france • in OpenGL ! • Regional languages of France • from ALF points
let’s see how to do it • Read files as input => csv + geojson • Use a lib to compute Voronoï =>openCV • Attach info to sites/points • Parse results (read openCV refs !!!) • Build the triangles and the colors (+holes + blue sea) • Tweak, adjust, set parameters, test and debug
Conclusion • Voronoï diagrams look cool • Voronoï diagrams are useful • Voronoï diagrams complement maps • Voronoï diagrams are fast to compute • Voronoï diagrams are complex to implement • Voronoï diagrams involve complex data structures • Voronoï diagrams are another tool in your toolbox