2d computer graphics
play

2D Computer Graphics Diego Nehab Summer 2020 IMPA 1 Bzier curves - PowerPoint PPT Presentation

2D Computer Graphics Diego Nehab Summer 2020 IMPA 1 Bzier curves Curve modeling by splines 2 Anchored in place by lead weights called ducks Physical process Interpolating, smooth, energy minimizing No local control Curve modeling by


  1. 2D Computer Graphics Diego Nehab Summer 2020 IMPA 1

  2. Bézier curves

  3. Curve modeling by splines 2

  4. Anchored in place by lead weights called ducks Physical process Interpolating, smooth, energy minimizing No local control Curve modeling by splines Thin strip of wood used in building construction 3

  5. Physical process Interpolating, smooth, energy minimizing No local control Curve modeling by splines Thin strip of wood used in building construction Anchored in place by lead weights called ducks 3

  6. Interpolating, smooth, energy minimizing No local control Curve modeling by splines Thin strip of wood used in building construction Anchored in place by lead weights called ducks Physical process 3

  7. No local control Curve modeling by splines Thin strip of wood used in building construction Anchored in place by lead weights called ducks Physical process Interpolating, smooth, energy minimizing ✓ 3

  8. Curve modeling by splines Thin strip of wood used in building construction Anchored in place by lead weights called ducks Physical process Interpolating, smooth, energy minimizing ✓ No local control ✗ 3

  9. Burmester curve 4

  10. Lagrangian interpolation Computational process k + 1 vertices { p 0 , . . . , p k } defjne a curve k � j � = i ( t − j ) � γ ( t ) = p i t ∈ [ 0 , k ] j � = i ( i − j ) , � i = 0 Similar issues 5

  11. B-splines Defjne a family of generating functions β n recursively  − 1 2 ≤ t < 1 1 ,  β 0 ( t ) = 2 0 , otherwise  β n = β n − 1 ∗ β 0 , n ∈ N Notation for convolution � ∞ h = f ∗ g ⇔ h ( t ) = f ( u ) g ( u − t ) dt −∞ 6

  12. B-splines Defjne a family of generating functions β n recursively  − 1 2 ≤ t < 1 1 ,  β 0 ( t ) = 2 0 , otherwise  β n = β n − 1 ∗ β 0 , n ∈ N Notation for convolution � ∞ h = f ∗ g ⇔ h ( t ) = f ( u ) g ( u − t ) dt −∞ 1. 0.8 0.6 0.4 0.2 6 - 4 - 2 2 - 0.2

  13. B-splines Defjne a family of generating functions β n recursively  − 1 2 ≤ t < 1 1 ,  β 0 ( t ) = 2 0 , otherwise  β n = β n − 1 ∗ β 0 , n ∈ N Notation for convolution � ∞ h = f ∗ g ⇔ h ( t ) = f ( u ) g ( u − t ) dt −∞ 1. 1. 0.8 0.8 0.6 0.6 0.4 0.4 0.2 0.2 6 - 4 - 2 - 4 2 - 2 2 - 0.2 - 0.2

  14. B-splines Defjne a family of generating functions β n recursively  − 1 2 ≤ t < 1 1 ,  β 0 ( t ) = 2 0 , otherwise  β n = β n − 1 ∗ β 0 , n ∈ N Notation for convolution � ∞ h = f ∗ g ⇔ h ( t ) = f ( u ) g ( u − t ) dt −∞ 1. 1. 1. 0.8 0.8 0.8 0.6 0.6 0.6 0.4 0.4 0.4 0.2 0.2 0.2 6 - 4 - 2 - 4 2 - 2 - 4 2 - 2 2 - 0.2 - 0.2 - 0.2

  15. B-splines Defjne a family of generating functions β n recursively  − 1 2 ≤ t < 1 1 ,  β 0 ( t ) = 2 0 , otherwise  β n = β n − 1 ∗ β 0 , n ∈ N Notation for convolution � ∞ h = f ∗ g ⇔ h ( t ) = f ( u ) g ( u − t ) dt −∞ 1. 1. 1. 1. 0.8 0.8 0.8 0.8 0.6 0.6 0.6 0.6 0.4 0.4 0.4 0.4 0.2 0.2 0.2 0.2 6 - 4 - 2 - 4 2 - 2 - 4 2 - 2 - 4 2 - 2 2 - 0.2 - 0.2 - 0.2 - 0.2

  16. 1 t 1 t 0 1 t 1 t 0 t 1 0 otherwise 1 3 1 2 t 2 8 3 t 2 2 1 4 t 2 1 1 4 3 t 2 t 2 2 1 4 t 2 1 2 8 9 12 t t 2 2 0 otherwise B-splines Examples  − 1 2 ≤ t < 1 1 ,  β 0 ( t ) = 2 0 , otherwise  7

  17. 1 3 1 2 t 2 8 3 t 2 2 1 4 t 2 1 1 4 3 t 2 t 2 2 1 4 t 2 1 2 8 9 12 t t 2 2 0 otherwise B-splines Examples  − 1 2 ≤ t < 1 1 ,  β 0 ( t ) = 2 0 , otherwise   1 + t , − 1 ≤ t < 0    β 1 ( t ) = 1 − t , 0 ≤ t < 1   0 , otherwise  7

  18. B-splines Examples  − 1 2 ≤ t < 1 1 ,  β 0 ( t ) = 2 0 , otherwise   1 + t , − 1 ≤ t < 0    β 1 ( t ) = 1 − t , 0 ≤ t < 1   0 , otherwise   1 − 3 2 ≤ t < − 1 8 ( 3 + 2 t ) 2 ,  2    4 ( 3 − 4 t 2 ) , 1 − 1 2 ≤ t < 1   β 2 ( t ) = 2 8 ( 9 − 12 t + 4 t 2 ) , 1 2 ≤ t < 2 1   2    0 , otherwise  7

  19. Local control Differentiable n times everywhere Non-interpolating • Interpolation requires solving a banded linear system Many, many interesting properties B-splines k + 1 vertices { p 0 , . . . , p k } and generating function β n defjne a curve k � β n ( t − i ) p i , γ ( t ) = t ∈ [ 0 , k ] i = 0 8

  20. Differentiable n times everywhere Non-interpolating • Interpolation requires solving a banded linear system Many, many interesting properties B-splines k + 1 vertices { p 0 , . . . , p k } and generating function β n defjne a curve k � β n ( t − i ) p i , γ ( t ) = t ∈ [ 0 , k ] i = 0 Local control ✓ 8

  21. Non-interpolating • Interpolation requires solving a banded linear system Many, many interesting properties B-splines k + 1 vertices { p 0 , . . . , p k } and generating function β n defjne a curve k � β n ( t − i ) p i , γ ( t ) = t ∈ [ 0 , k ] i = 0 Local control ✓ Differentiable n times everywhere ✓ 8

  22. Many, many interesting properties B-splines k + 1 vertices { p 0 , . . . , p k } and generating function β n defjne a curve k � β n ( t − i ) p i , γ ( t ) = t ∈ [ 0 , k ] i = 0 Local control ✓ Differentiable n times everywhere ✓ Non-interpolating ✗ • Interpolation requires solving a banded linear system ✓ 8

  23. B-splines k + 1 vertices { p 0 , . . . , p k } and generating function β n defjne a curve k � β n ( t − i ) p i , γ ( t ) = t ∈ [ 0 , k ] i = 0 Local control ✓ Differentiable n times everywhere ✓ Non-interpolating ✗ • Interpolation requires solving a banded linear system ✓ Many, many interesting properties 8

  24. Each segment defjned by linear interpolation i t 1 t p i t p i i 0 k 1 1 Local control Interpolates all control points Not differentiable at interpolated points Polylines k + 1 vertices { p 0 , . . . , p k } defjne k segments � � γ 0 ( t ) , . . . , γ k − 1 ( t ) t ∈ [ 0 , 1 ] , 9

  25. Local control Interpolates all control points Not differentiable at interpolated points Polylines k + 1 vertices { p 0 , . . . , p k } defjne k segments � � γ 0 ( t ) , . . . , γ k − 1 ( t ) t ∈ [ 0 , 1 ] , Each segment defjned by linear interpolation γ i ( t ) = ( 1 − t ) p i + t p i + 1 , i ∈ { 0 , . . . , k − 1 } 9

  26. Interpolates all control points Not differentiable at interpolated points Polylines k + 1 vertices { p 0 , . . . , p k } defjne k segments � � γ 0 ( t ) , . . . , γ k − 1 ( t ) t ∈ [ 0 , 1 ] , Each segment defjned by linear interpolation γ i ( t ) = ( 1 − t ) p i + t p i + 1 , i ∈ { 0 , . . . , k − 1 } Local control ✓ 9

  27. Not differentiable at interpolated points Polylines k + 1 vertices { p 0 , . . . , p k } defjne k segments � � γ 0 ( t ) , . . . , γ k − 1 ( t ) t ∈ [ 0 , 1 ] , Each segment defjned by linear interpolation γ i ( t ) = ( 1 − t ) p i + t p i + 1 , i ∈ { 0 , . . . , k − 1 } Local control ✓ Interpolates all control points ✓ 9

  28. Polylines k + 1 vertices { p 0 , . . . , p k } defjne k segments � � γ 0 ( t ) , . . . , γ k − 1 ( t ) t ∈ [ 0 , 1 ] , Each segment defjned by linear interpolation γ i ( t ) = ( 1 − t ) p i + t p i + 1 , i ∈ { 0 , . . . , k − 1 } Local control ✓ Interpolates all control points ✓ Not differentiable at interpolated points ✗ 9

  29. Polylines k + 1 vertices { p 0 , . . . , p k } defjne k segments � � γ 0 ( t ) , . . . , γ k − 1 ( t ) t ∈ [ 0 , 1 ] , Each segment defjned by linear interpolation γ i ( t ) = ( 1 − t ) p i + t p i + 1 , i ∈ { 0 , . . . , k − 1 } Local control ✓ Interpolates all control points ✓ Not differentiable at interpolated points ✗ 9

  30. kn 1 vertices p 0 p kn defjne k segments of degree n n n n 0 t n t 1 n t t 0 1 k Defjned recursively, for j 0 k 1 0 i t p i i nj n j 1 m m 1 m 1 t 1 t t t t i nj n j 1 m i i i 1 De Casteljau algorithm Geometric interpretation Bézier curves Generalization of linear interpolation 10

  31. Defjned recursively, for j 0 k 1 0 i t p i i nj n j 1 m m 1 m 1 t 1 t t t t i nj n j 1 m i i i 1 De Casteljau algorithm Geometric interpretation Bézier curves Generalization of linear interpolation kn + 1 vertices { p 0 , . . . , p kn } defjne k segments of degree n � γ n 0 ( t ) , γ n n ( t ) , . . . , γ n � ( k − 1 ) n ( t ) t ∈ [ 0 , 1 ] , 10

  32. De Casteljau algorithm Geometric interpretation Bézier curves Generalization of linear interpolation kn + 1 vertices { p 0 , . . . , p kn } defjne k segments of degree n � γ n 0 ( t ) , γ n n ( t ) , . . . , γ n � ( k − 1 ) n ( t ) t ∈ [ 0 , 1 ] , Defjned recursively, for j ∈ { 0 , . . . , k − 1 } � � γ 0 i ( t ) = p i , i ∈ nj , . . . , n ( j + 1 ) , γ m i ( t ) = ( 1 − t ) γ m − 1 ( t ) + t γ m − 1 � � i + 1 ( t ) , i ∈ nj , . . . , n ( j + 1 ) − m i 10

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend