21
Curvature-based blending of closed planar curves Teseo Schneider University of Lugano joint work with Marianna Saba, Kai Hormann, Riccardo Scateni

Curvature-based blending of closed planar curves

Embed Size (px)

Citation preview

Page 1: Curvature-based blending of closed planar curves

Curvature-based blending of closed planar curves

Teseo Schneider University of Lugano

joint work with

Marianna Saba, Kai Hormann, Riccardo Scateni

Page 2: Curvature-based blending of closed planar curves

Introduction

!  Blend between two closed curves !  the intermediate curve is closed !  the method is intrinsic

Curves and Surfaces 2014 – Paris – 13 June 2014

°0   °1  °t  °t  

Page 3: Curvature-based blending of closed planar curves

Our approach

Curves and Surfaces 2014 – Paris – 13 June 2014

Input curves  

Common parameterization  

Page 4: Curvature-based blending of closed planar curves

Common parameterization

!  Reparameterize ° 0 and ° 1 to arc-length ° 0 : [0, L0] ! R2 ° 1 : [0, L1] ! R2

!  Reparameterize and scale ° 0 and ° 1 to unit-length ° 0(s) = ° 0(L0s) / L0

° 1(s) = ° 1(L1s) / L1

!  ° 0 and ° 1 map from [0, 1] to R2

!  Scale back °t with Lt = (1 — t) L0 + t L1

Curves and Surfaces 2014 – Paris – 13 June 2014

Page 5: Curvature-based blending of closed planar curves

Parameterization based Parameterization-based blending !  °t(s)= (1 — t) °0(s) + t °1(s)

!  close intermediate curve !  depends on the orientation

Curves and Surfaces 2014 – Paris – 13 June 2014

Page 6: Curvature-based blending of closed planar curves

Curvature

!  Signed curvature

!  For any k there is a matching curve °, unique up to !  global rotation µ0

!  global translation y0

!  Compute angles µ(s)

!  Reconstruct curve °(s)

Curves and Surfaces 2014 – Paris – 13 June 2014

[do Carmo 1976]  

✓(s) =

Z s

0k(u)du+ ✓0

k(s) = det(°0(s), °00(s))  

�(s) =

Z s

0

✓cos ✓(u)sin ✓(u)

◆du+ y0

Page 7: Curvature-based blending of closed planar curves

Curvature based

!  Curvature-based blending !  kt(s)=(1 — t) k0(s) + t k1(s)

!  open intermediate curve !  intrinsic result

Curves and Surfaces 2014 – Paris – 13 June 2014

Page 8: Curvature-based blending of closed planar curves

Our approach

Curves and Surfaces 2014 – Paris – 13 June 2014

Common arc-length

parameterization  

0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1−1.5

−1

−0.5

0

0.5

1

1.5

2

2.5

0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1−1.5

−1

−0.5

0

0.5

1

1.5

2

2.5

Curvature  

0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1−1.5

−1

−0.5

0

0.5

1

1.5

2

2.5

°t  °0

°1

k0 k1 kt  ˜

Page 9: Curvature-based blending of closed planar curves

Close the curve

Curves and Surfaces 2014 – Paris – 13 June 2014

!  Find °t with curvature kt such that !  °t is closed !  kkt — ktk2 is minimal ˜

Close in curvature  

Close in Euclidean space

0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1−0.5

0

0.5

1

1.5

0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1−0.5

0

0.5

1

1.5

Theorem If kkt — kt k2 ∙ " then

k°t — °t k2 ∙ "

˜

˜

Page 10: Curvature-based blending of closed planar curves

Discretization

Curves and Surfaces 2014 – Paris – 13 June 2014

Input curves  Input polygons  

Common arc-length

parameterization  

Page 11: Curvature-based blending of closed planar curves

Discrete curvature

ki = 2®i / (si + si+1)

Curves and Surfaces 2014 – Paris – 13 June 2014

p1 p0= pn

pi

pn¡1

®i°

sisi+1

Z 1

0k(s)ds =

n�1X

i=0

ki = 2⇡�

0 0.2 0.4 0.6 0.8 1−0.4

−0.2

0

0.2

0.4

0.6

0.8

1

1.2

0 0.2 0.4 0. 6 0. 8 1−0.4

−0.2

0

0.2

0.4

0.6

0.8

1

1.2

0 0.2 0.4 0. 6 0. 8 1

−0.5

0

0.5

1

1.5

2

0 0.2 0.4 0. 6 0. 8 1−0.4

−0.2

0

0.2

0.4

0.6

0.8

1

1.2

Page 12: Curvature-based blending of closed planar curves

Discretization

Curves and Surfaces 2014 – Paris – 13 June 2014

Common arc-length

parameterization  

0 0.2 0.4 0. 6 0. 8 1

−1

−0.5

0

0.5

1

0 0.2 0.4 0. 6 0. 8 1−0.4

−0.2

0

0.2

0.4

0.6

0.8

1

1.2

Curvature  

0 0.2 0.4 0. 6 0. 8 1

0

0.1

0.2

0.3

0.4

0.5

0.6

0.7

0.8

0.9

Interpolated curvature kt,i ˜

Page 13: Curvature-based blending of closed planar curves

Discretization

Curves and Surfaces 2014 – Paris – 13 June 2014

0 0.2 0.4 0. 6 0. 8 1

−1

−0.5

0

0.5

1

0 0.2 0.4 0. 6 0. 8 1−0.4

−0.2

0

0.2

0.4

0.6

0.8

1

1.2

0 0.2 0.4 0. 6 0. 8 1

0

0.1

0.2

0.3

0.4

0.5

0.6

0.7

0.8

0.9

Interpolated curvature kt,i  ˜

subject to p0(®) = pn(®)  

min↵i,t

nX

i=0

⇣ ↵̃i,t � ↵i,t

si,t � si+1,t

⌘2

0 0.2 0.4 0. 6 0. 8 1

0

0.1

0.2

0.3

0.4

0.5

0.6

0.7

0.8

0.9

Page 14: Curvature-based blending of closed planar curves

Discretization

Curves and Surfaces 2014 – Paris – 13 June 2014

subject to p0 = pn  

min↵i,t

nX

i=0

⇣ ↵̃i,t � ↵i,t

si,t � si+1,t

⌘2

Page 15: Curvature-based blending of closed planar curves

Examples

Curves and Surfaces 2014 – Paris – 13 June 2014

Page 16: Curvature-based blending of closed planar curves

Examples

Curves and Surfaces 2014 – Paris – 13 June 2014

Page 17: Curvature-based blending of closed planar curves

Alternative approaches

!  Linear !  Fit a B-spline to the input curves !  Interpolate linearly the control polygon

!  Sederberg !  Fit a B-spline to the input curves !  Interpolate edges and lengths

!  Metamorphosis !  Linearly interpolate curvature !  Fit a spline to the open curve !  Close the control polygon ensuring G2

Curves and Surfaces 2014 – Paris – 13 June 2014

[Sederberg 1992 ]  

[Surazhsky 2002]  

Page 18: Curvature-based blending of closed planar curves

Comparison

Curves and Surfaces 2014 – Paris – 13 June 2014

Line

ar

Sede

rberg

Our

Metam

orph

osis

Page 19: Curvature-based blending of closed planar curves

Comparison

Curves and Surfaces 2014 – Paris – 13 June 2014

0 0.2 0.4 0.6 0.8 1−60

−40

−20

0

20

40

60curvature

s

linearSederbergmetamorphosisour

target

Page 20: Curvature-based blending of closed planar curves

Comparison

Curves and Surfaces 2014 – Paris – 13 June 2014

0 0.2 0.4 0.6 0.8 10

5

10

15

20

25

30

t

L2 e

rror

linearSederbergmetamorphosisour

Page 21: Curvature-based blending of closed planar curves

Curves and Surfaces 2014 – Paris – 13 June 2014

Thanks!