This article introduces a practical error metric for approximating Euler spirals and parallel curves using arc segments. Unlike earlier methods requiring complex continuity constraints or high computational costs, this approach achieves near-optimal accuracy with much simpler formulas and constant subdivision density. By empirically refining curvature-based error estimates, it produces visually smooth, watertight renders with fewer segments—making it ideal for efficient digital stroking and curve rendering applications.This article introduces a practical error metric for approximating Euler spirals and parallel curves using arc segments. Unlike earlier methods requiring complex continuity constraints or high computational costs, this approach achieves near-optimal accuracy with much simpler formulas and constant subdivision density. By empirically refining curvature-based error estimates, it produces visually smooth, watertight renders with fewer segments—making it ideal for efficient digital stroking and curve rendering applications.

A Simpler Formula for Curve Approximation Using Arc Segments

2025/10/29 23:15

ABSTRACT

1 INTRODUCTION

2 FLATTENING AND ARC APPROXIMATION OF CURVES

3 EULER SPIRALS AND THEIR PARALLEL CURVES

4 FLATTENED PARALLEL CURVES

5 ERROR METRICS FOR APPROXIMATION BY ARCS

6 EVOLUTES

7 CONVERSION FROM CUBIC BÉZIERS TO EULER SPIRALS

8 GPU IMPLEMENTATION

9 RESULTS

CONCLUSIONS, FUTURE WORK AND REFERENCES

\

ERROR METRICS FOR APPROXIMATION BY ARCS

The problem of approximating a curve by a sequence of arc segments has extensive literature, but none of the published solutions are quite suitable for our application. The specific problem of approximating an Euler spiral by arcs is considered in Meek and Walton [2004] using a “cut then measure” adaptive subdivision scheme, but their solution has poor quality; it scales as 𝑂(1/𝑛 2 ), while 𝑂(1/𝑛 3 ) is attainable. The result was improved “slightly” by Narayan [2014].

\ The literature also contains optimal results, namely Maier [2014] and Nuntawisuttiwong and Dejdumrong [2021], but at considerable cost; both approaches claim 𝑂(𝑛 2 ) time complexity. The through-line for all these results is that they are solving a harder problem: adopting the constraint that the generated arc sequence is 𝐺 1 continuous. While desirable for many applications, this constraint is not needed for rendering a stroke outline.

\ Even with this constraint relaxed, the angle discontinuities of an arc approximation are tiny compared to flattening to lines. Our approach is based on a simple error metric, similar in flavor to the one for flattening to line segments. The details of the metric (in particular, tuning of constants) were obtained empirically, though we suspect that more rigorous analytic bounds could be obtained. In practice it works very well indeed; the best way to observe that is an interactive testing tool, which is provided in the supplemental materials.

The proposed error metric is as follows. The estimated distance error for a curve of length 𝑠ˆ is:

𝑑 ≈ 1 120 ∫ 𝑠ˆ 0 3 √︁ |𝜅 ′ (𝑠)|𝑑𝑠!3

For an Euler spiral segment, 𝜅 ′ (𝑠) is constant and thus this error metric becomes nearly trivial. With 𝑛 subdivisions, the estimated distance is simply 𝑠 3𝜅 ′ 120𝑛 3 . Solving for 𝑛, we get 𝑛 = 𝑠 3 √︃ |𝜅 ′ | 120𝑑 subdivisions, and those are divided evenly by arc length, as the subdivision density is constant across the curve, just as is the case for flattening arcs to lines. Remarkably, the approximation of an Euler spiral parallel curve by arc segments is almost as simple as that for Euler spirals to arcs.

\ As in flattening to lines, the parameter for the curve is the arc length of the originating Euler spiral. The subdivision density is then constant, and only a small tweak is needed to the formula for computing the number of subdivisions, taking into account the additional curvature variation from the offset by ℎ (the half line-width). The revised formula is:

𝑛 = 𝑠 3 √︂ |𝜅 ′ | (1 + 0.4|ℎ𝑠𝜅′ |) 120𝑑

This formula was determined empirically by curve-fitting measured error values from approximating Euler spiral parallel curves to arcs, but was also inspired by applying the general error metric formula to the analytical equations for Euler spiral parallel curve, and dropping higher order terms. A more rigorous derivation, ideally with firm error bounds, remains as future work.

\ One consequence of this formula is that, since the error is in terms of the absolute value of ℎ, independent of sign, the same arc approximation can be used for both sides of a stroke. See Figure 8 for a comparison between flattening to a polyline and approximation with arc segments. The arc segment version has many fewer segments at the same tolerance, while preserving very high visual quality.

EVOLUTES

In the principled, correct specification for stroking [19], parallel curves are sufficient only for segments in which the curvature

\ Figure 9: Weakly and strongly correct stroke outlines. The toprow shows weakly correct stroke outlines. In (a) the curvature does

\ does not exceed the reciprocal half-width. When it does, additional segments must be drawn, including evolutes of the original curve. In general, the evolute of a cubic Bézier is a very complex curve, requiring approximation techniques. By contrast, the evolute of an Euler spiral (𝜅 = 𝑎𝑠) is another spiral with a simple Cesàro equation, namely 𝜅 = −𝑎 −1 𝑠 −3 , an instance of the general result that the evolute of a log-aesthetic curve is another log-aesthetic curve [26].

\ Flattening this evolute is also straightforward; the subdivision density is proportional to 𝑠 −0.5 where 𝑠 is the arc length parameter of the underlying Euler spiral (and translated so 𝑠 = 0 is the inflection point). Thus, the integral is 2 √ 𝑠, and the inverse integral is just squaring. Thus, flattening the evolute of an Euler spiral is simpler than flattening its parallel curve. T

\ he effect of adding evolutes to achieve strong correctness is shown in Figure 9. The additional evolute segments and connecting lines are output twice, to make the winding numbers consistent and produce a watertight outline. All winding numbers are positive, so rendering with the nonzero winding rule yields a correct final render.

:::info Authors:

  1. Raph Levien
  2. Arman Uguray

:::

:::info This paper is available on arxiv under CC 4.0 license.

:::

\

Disclaimer: The articles reposted on this site are sourced from public platforms and are provided for informational purposes only. They do not necessarily reflect the views of MEXC. All rights remain with the original authors. If you believe any content infringes on third-party rights, please contact service@support.mexc.com for removal. MEXC makes no guarantees regarding the accuracy, completeness, or timeliness of the content and is not responsible for any actions taken based on the information provided. The content does not constitute financial, legal, or other professional advice, nor should it be considered a recommendation or endorsement by MEXC.

You May Also Like

The HackerNoon Newsletter: Cypherpunks Write Code: Zooko Wilcox  Zcash (9/21/2025)

The HackerNoon Newsletter: Cypherpunks Write Code: Zooko Wilcox Zcash (9/21/2025)

How are you, hacker? 🪐 What’s happening in tech today, September 21, 2025? The HackerNoon Newsletter brings the HackerNoon homepage straight to your inbox. On this day, Malta's Independence Day in 1964, U.S.A. Neutrality Acts in 1939, Belize Gained Full Independence in 1981, and we present you with these top quality stories. From Remote Work Reality Check: Malta, Madeira and the Canaries to Terraforming Mars Could Save Earth (or Doom Us All), let’s dive right in. Can You Spend Crypto Without Selling It? Inside The ether.fi Cash Card’s “Never Sell” Revolution By @ishanpandey [ 10 Min read ] In-depth review of the Ether.Fi Cash Card – a DeFi-driven Visa that lets you spend crypto without selling it. Read More. How Evergen Scaled Renewable Monitoring with TigerData (TimescaleDB) and Slashed Infrastructure Cost By @tigerdata [ 9 Min read ] How Evergen scaled renewable monitoring by moving from MongoDB to TigerData (TimescaleDB)—cutting infra use >50%, speeding queries <500 ms, centralizing data. Read More. From Postgres to ScyllaDB: How Coralogix Achieved 349x Faster Queries By @scylladb [ 8 Min read ] Coralogix boosted query speeds 349x by migrating from PostgreSQL to ScyllaDB, cutting latency from 30s to 86ms with smart data modeling. Read More. Remote Work Reality Check: Malta, Madeira and the Canaries By @socialdiscoverygroup [ 4 Min read ] Remote Work in Paradise? 4 Years, 3 Islands, 1 Honest Guide. Discover the real trade-offs of Malta, Madeira Canary Islands for digital nomads. Read More. Cypherpunks Write Code: Zooko Wilcox Zcash By @obyte [ 6 Min read ] Zooko Wilcox grew up coding and questioning systems, and that path led him to create the privacy coin Zcash. Lets see more of this story! Read More. Why a Decentralized Internet is Inevitable (or Not) by 2030 By @awesomemike [ 8 Min read ] Explore the arguments for and against a decentralized internet by 2030, examining technology, regulation, and societal impact shaping its future. Read More. Terraforming Mars Could Save Earth (or Doom Us All) By @kingdavvd [ 6 Min read ] Explore how space technology helps fight climate change, from satellites tracking emissions to innovations driving sustainability. Read More. Bitcoin Highs Bring Familiar Questions, but Discipline Outlasts Hype By @paulquickenden [ 3 Min read ] Bitcoin has hit a new high price - but is it the top? What could push it higher or lower? Heres a steady, hype-free take on reading the signals Read More. 🧑‍💻 What happened in your world this week? It's been said that writing can help consolidate technical knowledge, establish credibility, and contribute to emerging community standards. Feeling stuck? We got you covered ⬇️⬇️⬇️ ANSWER THESE GREATEST INTERVIEW QUESTIONS OF ALL TIME We hope you enjoy this worth of free reading material. Feel free to forward this email to a nerdy friend who'll love you for it.See you on Planet Internet! With love, The HackerNoon Team ✌️
Share
Hackernoon2025/09/22 00:02