Elsevier

Computers & Graphics

Volume 26, Issue 6, December 2002, Pages 841-852
Computers & Graphics

Robust adaptive polygonal approximation of implicit curves

https://doi.org/10.1016/S0097-8493(02)00173-5Get rights and content

Abstract

We present an algorithm for computing a robust adaptive polygonal approximation of an implicit curve in the plane. The approximation is adapted to the geometry of the curve because the length of the edges varies with the curvature of the curve. Robustness is achieved by combining interval arithmetic and automatic differentiation.

Introduction

An implicit object is defined as the set of solutions of an equation f(p)=0, where f:ΩRnR. For well-behaved functions f, this set is a manifold of dimension n−1 in Rn. Of special interest to computer graphics are implicit curves (n=2) and implicit surfaces (n=3), although several problems in computer graphics can be formulated as high-dimensional implicit problems [1], [2].

Applications usually need a geometric model of the implicit object, typically a polygonal approximation. While it is easy to compute polygonal approximations for parametric objects, computing polygonal approximations for implicit objects is a challenging problem for two main reasons: first, it is difficult to find points on the implicit object [3]; second, it is difficult to connect isolated points into a mesh [4].

In this paper, we consider the problem of computing a polygonal approximation for a curve C given implicitly by a function f:ΩR2R, i.e.C={(x,y)R2:f(x,y)=0}.In Section 2 we review some methods for approximating implicit curves, and in Section 3 we show how to compute robust adaptive polygonal approximations. By “adaptive” we mean two things: first, Ω is explored adaptively, in the sense that effort is concentrated on the regions of Ω that are near C; second, the polygonal approximation is adapted to the geometry of C, having longer edges where C is flat and the curvature is low, and shorter edges where C bends more and the curvature is high. By “robust” we mean that the algorithm finds all pieces of C in Ω (implicit curves can have several connected components) and that it estimates correctly the variation of curvature along C to identify pieces of Ω where C can be well approximated by straight lines. In other words, the computed approximation captures efficiently both the topology and the geometry of C. Adaption and robustness are achieved by combining interval arithmetic and automatic differentiation, which are explained in Section 3.

An example of what our algorithm does is shown in Fig. 1 for the ellipse given implicitly by the equation x2/6+y2=1. Further examples are given in Section 3.6.

Section snippets

Approximating implicit curves

Approximating a curve C given implicitly by f:ΩR is a difficult problem mainly because it is difficult to find just where C lies in Ω: it can be anywhere (even nowhere) in Ω and it can have several components, of varying size, some of which may be closed and nested inside each other.

The classical method for avoiding chasing C blindly inside Ω is to decompose Ω into a grid of small rectangular or triangular cells and then traverse the grid and locate C by identifying those cells that intersect C

Robust adaptive polygonal approximation

As discussed in Section 2, what we need for robust adaptive enumeration is some kind of oracle that reliably answers the question “Does this cell intersect C?”. Testing the sign of f at the vertices of the cell is an oracle, but not a reliable one. It turns out that it is easier to implement oracles that reliably answer the complementary question “Is this cell away from C?”. Such oracles test the absence of C in the cell, rather than its presence, but they are just as effective for reliable

Related work

Early work on implicit curves in computer graphics concentrated on rendering, and consisted mainly of continuation methods in image space. Aken and Novak [28] showed how Bresenham's algorithm for circles can be adapted to render more general curves, but they only gave details for conics. Their work was later expanded by Chandler [29]. These two papers contain several references to the early work on the rendering problem. More recently, Glassner [30] discussed in detail a continuation algorithm

Conclusion

Algorithm 2 computes robust adaptive polygonal approximation of implicit curves. As far as we know, this is the first algorithm which computes a reliable enumeration that is both spatially and geometrically adaptive.

The natural next step in this research is to attack implicit surfaces, which have recently become again an active research area [37]. The ideas and techniques presented in this paper are useful for computing robust adaptive approximations of implicit surfaces. However, the solution

Acknowledgements

This research was done while J.B. Oliveira was visiting the Visgraf laboratory at IMPA during IMPA's summer post-doctoral program. Visgraf is sponsored by CNPq, FAPERJ, FINEP, and IBM Brasil. H. Lopes is a member of the Matmidia laboratory at PUC-Rio. Matmidia is sponsored by FINEP, PETROBRAS, CNPq, and FAPERJ. L. H. de Figueiredo is a member of Visgraf and is partially supported by a CNPq research grant.

References (37)

  • S.P Mudur et al.

    Interval methods for processing geometric objects

    IEEE Computer Graphics & Applications

    (1984)
  • D.L Toth

    On ray tracing parametric surfaces

    Computer Graphics

    (1985)
  • Mitchell DP, Robust ray intersection with interval arithmetic. In: Proceedings of Graphics Interface’90, 1990. p....
  • J.M Snyder

    Generative modeling for computer graphics and CAD

    (1992)
  • T Duff

    Interval arithmetic and recursive subdivision for implicit functions and constructive solid geometry

    Computer Graphics

    (1992)
  • W Barth et al.

    Ray tracing general parametric surfaces using interval arithmetic

    The Visual Computer

    (1994)
  • Oliveira JB, de Figueiredo LH. Robust approximation of offsets and bisectors of plane curves. In: Proceedings of...
  • Mitchell DP. Three applications of interval analysis in computer graphics. In: Frontiers in rendering course notes,...
  • Cited by (0)

    Based on “Robust adaptive approximation of implicit curves” by H. Lopes, J.B. Oliveira, and L.H. de Figueiredo, which appeared in Proceedings of SIBGRAPI 2001 (XIV Brazilian Symposium on Computer Graphics and Image Processing) pp. 10–17 © 2001 IEEE.

    View full text