This project generates a Voronoi diagram using Fortune's algorithm.
The implementation includes classes for points, events, arcs, segments,
and a priority queue. Additionally, a simple graphical user interface (GUI) is
provided using the tkinter
library for visualizing the Voronoi diagram
interactively.
-
Manually Add Points:
- Double-click on the canvas to add points manually.
-
Calculate Voronoi Diagram:
- Click the "Calculate" button to compute the Voronoi diagram based on the input points.
-
Visualize Steps:
- Click the "Next" button to visualize each step of the algorithm.
-
Clear Canvas:
- Click the "Clear" button to reset the canvas and add new points.
-
Clone the repository:
git clone https://github.com/ShengyuanWang/COMP494-MINI-PROJECT-2.git
-
Navigate to the project directory:
cd Voroni
-
Run the script:
python3 test.py
The implementation is based on Fortune's algorithm for Voronoi diagram generation. Here are some references that were consulted during the development:
- Beach Line (Geometry) - Wikipedia
- Fortune's Algorithm - Wikipedia
- Voronoi Diagrams in Python
- Fortune's Algorithm: A Visual Explanation
- Fortune Algorithm Details
Special thanks to the authors and contributors of the referenced materials for providing valuable insights into the Voronoi diagram generation algorithm.