Computer Science Technical Reports
CS at VT

An Optimal Boundary to Quadtree Conversion Algorithm

Lattanzi, Mark and Shaffer, Clifford A. (1989) An Optimal Boundary to Quadtree Conversion Algorithm. Technical Report TR-89-16, Computer Science, Virginia Polytechnic Institute and State University.

Full text available as:
PDF - Requires Adobe Acrobat Reader or other PDF viewer.
TR-89-16.pdf (1137205)


An algorithm is presented for converting a boundary representation for an image to its region quad-tree representation. Our algorithm is designed for operation on the linear quadtree representation, although it can easily be modified for the traditional pointer-based quadtree representation. The algorithm is a two phase process that first creates linear quadtree node records for each of the border pixels. This list of pixels is then sorted by locational code. The second processing phase fills in the nodes interior to the polygons by simulating a traversal of the corresponding pointer-based quadtree. Three previous algorithms [Same80, Mark85a, Atki86] have described similar conversion routines requiring time complexity of O(n.B)for at least one of the two phases, where B is the number of boundary pixels and n is the depth of the final tree for a 2" x 2" image. A fourth algorithm [Webb84] can perform the border construction of this conversion in time O(n+B) with the restriction that the polygon must be positioned at constrained locations in the image space. Our algorithm requires time O(n + B) for the second phase, which is optimal. The first phase can be performed using the algorithm of [Webb84] for total conversion time of O(n + B) with constrained location, or in time O(B log B) using a simple sort to order the border pixels with no restriction in polygon location.

Item Type:Departmental Technical Report
Subjects:Computer Science > Historical Collection(Till Dec 2001)
ID Code:153
Deposited By:User autouser
Deposited On:05 December 2001