Abstract
A variant of the plane-sweep paradigm known as topological sweep is adapted to solve geometric problems involving two-dimensional regions when the underlying representation is a region quadtree. The utility of this technique is illustrated by showing how it can be used to extract the boundaries of a map inO(M) space andO(Mα(M)) time, whereM is the number of quadtree blocks in the map, andα(·) is the (extremely slowly growing) inverse of Ackerman's function. The algorithm works for maps that contain multiple regions as well as holes. The algorithm makes use of active objects (in the form of regions) and an active border. It keeps track of the current position in the active border so that at each step no search is necessary. The algorithm represents a considerable improvement over a previous approach whose worst-case execution time is proportional to the product of the number of blocks in the map and the resolution of the quadtree (i.e., the maximum level of decomposition). The algorithm works for many different quadtree representations including those where the quadtree is stored in external storage.
Similar content being viewed by others
References
D. J. Abel and J. L. Smith. A data structure and algorithm based on a linear key for a rectangle retrieval problem.Computer Vision, Graphics, and Image Processing, 24(1):1–13, October 1983.
A. V. Aho, J. E. Hopcroft, and J. D. Ullman.The Design and Analysis of Computer Algorithms. Addison-Wesley, Reading, MA, 1974.
H. S. Baird. Fast algorithms for LSI artworks analysis.Journal of Design Automation & Fault-Tolerant Computing, 2:179–209, 1978.
M. Ben-Or. Lower bounds for algebraic computation trees.Proceedings of the Fifteenth Annual ACM Symposium on the Theory of Computing, pp. 80–86, Boston, MA, April 1983.
J. L. Bentley. Algorithms for Klee's rectangle problems. Unpublished manuscript, Computer Science Department, Carnegie-Mellon University, Pittsburgh, PA, 1977.
J. L. Bentley and D. Wood. An optimal worst-case algorithm for reporting intersections of rectangles.IEEE Transactions on Computers, 29(7):571–576, July 1980.
M. B. Dillencourt, H. Samet, and M. Tamminen. A general approach to connected-component labeling for arbitrary image representations.Journal of the ACM, 39(3):253–280, April 1992. Also see Corrigenda,Journal of the ACM, 39(4):985–985, October 1992.
C. R. Dyer, A. Rosenfeld, and H. Samet. Region representation: Boundary codes from quadtrees.Communications of the ACM, 23(3):171–179, March 1980.
H. Edelsbrunner. A new approach to rectangle intersections: part I.International Journal of Computer Mathematics, 13(3–4):209–219, 1983.
H. Edelsbrunner.Algorithms in Combinatorial Geometry. EATCS Monographs on Theoretical Computer Science, vol. 10. Springer-Verlag, Berlin, 1987.
H. Edelsbrunner and L. J. Guibas. Topologically sweeping an arrangement.Proceedings of the Eighteenth Annual ACM Symposium on the Theory of Computing, pp. 389–403, Berkeley, CA, May 1986.
H. Freeman. Computer processing of line-drawing images.ACM Computing Surveys, 6(1):57–97, March 1974.
I. Gargantini. An effective way to represent quadtrees.Communications of the ACM, 25(12):905–910, December 1982.
E. Kawaguchi, T. Endo, and J. Matsunaga. Depth-first picture expression viewed from digital picture processing.IEEE Transactions on Pattern Analysis andMachine Intelligence, 5(4):373–384, July 1983.
D. T. Lee. Maximum clique problem of rectangle graphs. In F. P. Preparata, editor,Computational Geometry, pp. 91–107. Advances in Computing Research, vol. 1. JAI Press, Greenwich, CT, 1983.
E. M. McCreight. Priority search trees.S1AM Journal on Computing, 14(2):257–276, May 1985.
J. Nievergelt and F. P. Preparata. Plane-sweep algorithms for intersecting geometric figures.Communications of the ACM, 25(10):739–747, October 1982.
F. P. Preparata and M. I. Shamos.Computational Geometry: An Introduction. Springer-Verlag, New York, 1985.
H. Samet. Hierarchical representations of collections of small rectangles.ACM Computing Surveys, 20(2):271–309, December 1988.
H. Samet.The Design and Analysis of Spatial Data Structures. Addison-Wesley, Reading, MA, 1990.
H. Samet and M. Tamminen. Computing geometric properties of images represented by linear quadtrees.IEEE Transactions on Pattern Analysis and Machine Intelligence, 7(3):229–240, March 1985.
H. Samet and M. Tamminen. Efficient component labeling of images of arbitrary dimension represented by linear bintrees.IEEE Transactions on Pattern Analysis and Machine Intelligence, 10(4):579–586, July 1988.
H. Samet and R. E. Webber. Storing a collection of polygons using quadtrees.ACM Transactions on Graphics, 4(3):182–222, July 1985.
M. Tamminen, Encoding pixel trees.Computer Graphics, Vision, and Image Processing, 28(1):44–57, October 1984.
R. E. Tarjan, Efficiency of a good but not linear set union algorithm.Journal of the ACM, 22(2):215–225, April 1975.
Author information
Authors and Affiliations
Additional information
Communicated by D. P. Dobkin.
M. B. Dillencourt was supported in part by a UCI Faculty Research Grant, and H. Samet was supported in part by the National Science Foundation under Grant IRI-90-17393.
Rights and permissions
About this article
Cite this article
Dillencourt, M.B., Samet, H. Using topological sweep to extract the boundaries of regions in maps represented by region quadtrees. Algorithmica 15, 82–102 (1996). https://doi.org/10.1007/BF01942608
Received:
Revised:
Issue Date:
DOI: https://doi.org/10.1007/BF01942608