, Volume 10, Issue 1, pp 1–23 | Cite as

An efficient algorithm for finding the CSG representation of a simple polygon

  • David Dobkin
  • Leonidas Guibas
  • John Hershberger
  • Jack Snoeyink


Modeling two-dimensional and three-dimensional objects is an important theme in computer graphics. Two main types of models are used in both cases: boundary representations, which represent the surface of an object explicitly but represent its interior only implicitly, and constructive solid geometry representations, which model a complex object, surface and interior together, as a boolean combination of simpler objects. Because neither representation is good for all applications, conversion between the two is often necessary.

We consider the problem of converting boundary representations of polyhedral objects into constructive solid geometry (CSG) representations. The CSG representations for a polyhedronP are based on the half-spaces supporting the faces ofP. For certain kinds of polyhedra this problem is equivalent to the corresponding problem for simple polygons in the plane. We give a new proof that the interior of each simple polygon can be represented by a monotone boolean formula based on the half-planes supporting the sides of the polygon and using each such half-plane only once. Our main contribution is an efficient and practicalO(n logn) algorithm for doing this boundary-to-CSG conversion for a simple polygon ofn sides. We also prove that such nice formulae do not always exist for general polyhedra in three dimensions.

Key words

Constructive solid geometry Computational geometry Boundary representation Monotone boolean formulae Incremental convex hull 


Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.


  1. [1]
    J. Boyse and J. Gilchrist. GMSolid: Interactive modeling for design and analysis of solids.IEEE Comput. Graphics and Applications, 2:86–97, 1982.Google Scholar
  2. [2]
    C. Brown. PADL-2: A technical summary.IEEE Comput. Graphics and Applications, 2:69–84, 1982.Google Scholar
  3. [3]
    M. H. Brown.Algorithm Animation. ACM Distinguished Dissertations. MIT Press, Cambridge, MA, 1988.Google Scholar
  4. [4]
    M. H. Brown. Zeus: A system for algorithm animation. InProceedings of the 1991 IEEE Workshop on Visual Languages, pages 4–9, October 1991.Google Scholar
  5. [5]
    M. H. Brown and J. Hershberger. Color and sound in algorithm animation.IEEE Trans, Comput., 25(12):52–63, 1992.Google Scholar
  6. [6]
    B. M. Chazelle. Computational Geometry and Convexity. Technical Report CMU-CS-80-150, Department of Computer Science, Carnegie-Mellon University, Pittsburgh, PA, 1980.Google Scholar
  7. [7]
    H. Edelsbrunner.Algorithms in Combinatorial Geometry. EATCS Monographs on Theoretical Computer Science, volume 10. Springer-Verlag, Berlin, 1987.Google Scholar
  8. [8]
    W. Franklin. Polygon properties calculated from the vertex neighborhoods. InProceedings of the 3rd ACM Symposium on Computational Geometry, pages 110–118, 1987.Google Scholar
  9. [9]
    R. L. Graham and F. F. Yao. Finding the convex hull of a simple polygon.J. Algorithms,4:324–331, 1983.Google Scholar
  10. [10]
    L. Guibas, J. Hershberger, D. Leven, M. Sharir, and R. Tarjan. Linear time algorithms for visibility and shortest path problems inside triangulated simple polygons.Algorithmica, 2:209–233, 1987.CrossRefGoogle Scholar
  11. [11]
    L. Guibas, L. Ramshaw, and J. Stolfi. A kinetic framework for computational geometry. InProceedings of the 24th IEEE Symposium on Foundations of Computer Science, pages 100–111, 1983.Google Scholar
  12. [12]
    J. Hershberger and M. H. Brown. Boolean Formulae for Simple Polygons. Research Report Videotape 50b, DEC Systems Research Center, Palo Alto, CA, 1989.Google Scholar
  13. [13]
    K. Hoffmann, K. Mehlhorn, P. Rosenstiehl, and R. E. Tarjan. Sorting Jordan sequences in linear time. InProceedings of the ACM Symposium on Computational Geometry, pages 196–203, 1985.Google Scholar
  14. [14]
    D. T. Lee. On finding the convex hull of a simple polygon.Internat. J. Comput. Inform. Sci., 12:87–98, 1983.Google Scholar
  15. [15]
    M. M. Mano.Digitial Logic and Computer Design. Prentice-Hall, Englewood Cliffs, NJ, 1979.Google Scholar
  16. [16]
    M. Mäntylä.An Introduction to Solid Modeling. Computer Science Press, Rockville, MD, 1987.Google Scholar
  17. [17]
    D. McCallum and D. Avis. A linear algorithm for finding the convex hull of a simple polygon.Inform. Process. Lett., 9:201–206, 1979.Google Scholar
  18. [18]
    A. Melkman. On-line construction of the convex hull of a simple polyline.Inform. Process. Lett., 25:11–12, 1987.Google Scholar
  19. [19]
    M. Mortenson.Geometric Modeling. Wiley, New York, 1985.Google Scholar
  20. [20]
    R. Newell. Solid modelling and parametric design in the Medusa system. InComputer Graphics '82, Proceedings of the Online Conference, pages 223–235, 1982.Google Scholar
  21. [21]
    J. O'Rourke.Art Gallery Theorems and Algorithms. Oxford University Press, Oxford, 1987.Google Scholar
  22. [22]
    M. Paterson and F. Yao. Binary partitions with applications to hidden-surface removal and solid modelling. InProceedings of the 5th ACM Symposium on Computational Geometry, pages 23–32, 1989.Google Scholar
  23. [23]
    T. Pavlidis. Analysis of set patterns.Pattern Recognition, 1:165–178, 1968.Google Scholar
  24. [24]
    D. Peterson. Halfspace Representation of Extrusions, Solids of Revolution, and Pyramids. SANDIA Report SAND84-0572, Sandia National Laboratories, Albuquerque, NM, 1984.Google Scholar
  25. [25]
    F. P. Preparata and M. I. Shamos.Computational Geometry. Springer-Verlag, New York, 1985.Google Scholar
  26. [26]
    A. Requicha. Representations for rigid solids: Theory, methods, and systems.ACM Comput. Surveys, 12:437–464, 1980.Google Scholar
  27. [27]
    A. A. Schäffer and C. J. Van Wyk. Convex hulls of piecewise-smooth Jordan curves.J. Algorithms, 8:66–94, 1987.Google Scholar
  28. [28]
    W. Tiller. Rational B-splines for curve and surface representation.IEEE Comput. Graphics and Applications, 3, 1983.Google Scholar
  29. [29]
    S. B. Tor and A. E. Middleditch. Convex decomposition of simple polygons.ACM Trans. Graphics, 3(4):244–265, 1984.Google Scholar
  30. [30]
    H. Voelcker, A. Requicha, E. Hartquist, W. Fisher, J. Metzger, R. Tilove, N. Birrell, W. Hunt, G. Armstrong, T. Check, R. Moote, and J. McSweeney. The PADL-1.0/2 system for defining and displaying solid objects.ACM Comput. Graphics, 12(3):257–263, 1978.Google Scholar
  31. [31]
    J. R. Woodwark and A. F. Wallis, Graphical input to a Boolean solid modeller. InProceedings of CAD 82, pages 681–688, Brighton, U.K., 1982.Google Scholar

Copyright information

© Springer-Verlag New York Inc 1993

Authors and Affiliations

  • David Dobkin
    • 1
  • Leonidas Guibas
    • 2
    • 3
  • John Hershberger
    • 3
  • Jack Snoeyink
    • 4
  1. 1.Department of Computer SciencePrinceton UniversityPrincetonUSA
  2. 2.Stanford UniversityStanfordUSA
  3. 3.DEC Systems Research CenterPalo AltoUSA
  4. 4.Department of Computer ScienceUniversity of British ColumbiaVancouverCanada

Personalised recommendations