[Paper Review] Efficient Computation of Visibility Polygons
This paper presents a novel triangular expansion algorithm for computing visibility polygons in simple and polygonal domains with holes, achieving sublinear practical performance despite an O(n²) worst-case theoretical bound. The method uses a triangulation-based recursive approach that restricts visibility through angular constraints, outperforming existing O(n) and O(n log n) algorithms by up to two orders of magnitude in real-world scenarios, particularly on complex inputs like the Norway and cathedral polygons.
Determining visibility in planar polygons and arrangements is an important subroutine for many algorithms in computational geometry. In this paper, we report on new implementations, and corresponding experimental evaluations, for two established and one novel algorithm for computing visibility polygons. These algorithms will be released to the public shortly, as a new package for the Computational Geometry Algorithms Library (CGAL).
Motivation & Objective
- To address the lack of exact, complete, and efficient implementations of visibility polygon algorithms in computational geometry libraries.
- To develop a new algorithm that achieves high practical performance for visibility computation in complex polygonal environments, especially with holes.
- To provide a robust, exact computation framework that handles degenerate cases and supports configurable output (including visibility antennae).
- To evaluate and compare the performance of the new algorithm against established O(n) and O(n log n) methods on real-world and worst-case inputs.
Proposed method
- The triangular expansion algorithm uses a triangulation of the input polygon to recursively explore visibility cones from the query point, pruning regions that are not visible.
- At each recursive step, the algorithm determines visibility using orientation tests to check if a new vertex lies within the current angular bounds defined by reflex vertices.
- The algorithm maintains a stack of active visibility cones and splits recursion when a vertex lies between the left and right angular bounds, leading to two recursive calls.
- The method leverages the fact that visibility cones can be restricted by reflex vertices, reducing the number of triangles processed even in worst-case scenarios.
- The algorithm is implemented with exact arithmetic to handle degeneracies and supports configurable output, including visibility antennae.
- Preprocessing involves triangulating the polygon, which takes O(n) time and space, and enables efficient visibility cone traversal during query processing.
Experimental results
Research questions
- RQ1Can a novel visibility polygon algorithm be designed that achieves sublinear practical performance despite a worst-case O(n²) theoretical bound?
- RQ2How does the performance of the triangular expansion algorithm compare to established O(n) and O(n log n) algorithms on real-world and worst-case inputs?
- RQ3To what extent does preprocessing via triangulation improve query efficiency for visibility computation in complex polygonal domains?
- RQ4Why do existing implementations of visibility algorithms remain absent or incomplete in major computational geometry libraries like CGAL?
Key findings
- The triangular expansion algorithm achieves an average query time of 0.18 ms per vertex on the Norway dataset (20,981 vertices), outperforming the O(n) Joe-Simpson algorithm by over 100x.
- On the cathedral dataset (1,209 vertices), the new algorithm runs in 0.004 ms per query, more than 100x faster than the rotational sweep algorithm.
- In the worst-case scenario with Θ(n) holes, the algorithm reaches O(n²) complexity, but this case is rare in practice and does not dominate real-world performance.
- The triangular expansion algorithm is more than 100x faster than the O(n log n) rotational sweep algorithm on the Norway dataset, demonstrating superior practical efficiency.
- The implementation is exact, handles all degenerate cases, and supports configurable output, including visibility antennae, making it production-ready for integration into CGAL.
- The authors report that the new algorithm is the first complete and exact implementation of its kind, with public release planned for CGAL 4.5.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.