07 designing interpolating curves
play

07 - Designing Interpolating Curves Acknowledgement: Olga - PowerPoint PPT Presentation

07 - Designing Interpolating Curves Acknowledgement: Olga Sorkine-Hornung, Alexander Sorkine-Hornung, Ilya Baran CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo How do we model shapes? Delcam Plc. [CC BY-SA 3.0


  1. 07 - Designing Interpolating Curves Acknowledgement: Olga Sorkine-Hornung, Alexander Sorkine-Hornung, Ilya Baran CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  2. How do we model shapes? Delcam Plc. [CC BY-SA 3.0 (http://creativecommons.org/licenses/by-sa/3.0) or GFDL (http://www.gnu.org/copyleft/fdl.html)], via Wikimedia Commons CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  3. Building blocks: curves and surfaces By Wojciech mula at Polish Wikipedia, CC BY-SA 3.0, https://commons.wikimedia.org/w/index.php?curid=9853555 CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  4. A modeling session • Demo with Keynote for 2D • Demo with Blender for 3D CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  5. Modeling curves • We need mathematical concepts to characterize the desired curve properties • Notions from curve geometry help with designing user interfaces for curve creation and editing CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  6. 2D parametric curve • must be continuous CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  7. A curve can be parameterized in many different ways CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  8. Tangent vector Parametrization-independent! CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  9. Arc length • How long is the curve between and ? How far does the particle travel? • Speed is , so: • Speed is nonnegative, so is non-decreasing CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  10. Arc length parameterization • Every curve has a natural parameterization: CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  11. Arc length parameterization • Every curve has a natural parameterization: • Isometry between parameter domain and curve • Tangent vector is unit-length: CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  12. Curvature • How much does the curve turn per unit ? CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  13. Curvature • How much does the curve turn per unit ? CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  14. Curvature profile • Given , we can get up to a constant by integration. Integrating reconstructs the curve up to rigid motion. CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  15. Curvature of a circle • Curvature of a circle: = Unit Normal Osculating circle CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  16. Frenet Frame CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  17. Curvature normal • Points inward • useful for evaluating curve quality CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  18. Smoothness Two kinds, parametric and geometric: Parametrization-Independent CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  19. Smoothness example CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  20. Recap on parametric curves CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  21. Turning • Angle from start tangent to end tangent: • If curve is closed, the tangent at the beginning is the same as the tangent at the end CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  22. Turning numbers 1 –1 2 0 • measures how many full turns the tangent makes. CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  23. Space curves (3D) • In 3D, many vectors are orthogonal to T B N • are the “Frenet frame” • is torsion: non-planarity T CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  24. Designing Curves: 
 Polynomials and Interpolation CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  25. Basic idea for curve design • User gives us points. We need to connect the dots in a smooth way. • The dots stay as “handles” on the curve. User can move the dots and the curve follows. CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  26. Basic idea for curve design • User gives us points. We need to connect the dots in a smooth way. • The dots stay as “handles” on the curve. User can move the dots and the curve follows. CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  27. Keynote Demo CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  28. Blender Demo CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  29. Polynomial curves • Polynomials • For degree we need points (“coefficients”) CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  30. 
 
 
 
 Polynomials • Parametric form with polynomials 
 • Control shape? CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  31. 
 
 
 
 Polynomials • Parametric form with polynomials 
 • Control shape? CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  32. 
 
 
 
 Polynomials • Parametric form with polynomials 
 • Control shape? CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  33. 
 
 
 
 Polynomials • Parametric form with polynomials 
 • Control shape? CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  34. 
 
 
 
 Polynomials • Parametric form with polynomials 
 • Control shape? CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  35. 
 
 
 
 Polynomials • Parametric form with polynomials 
 • Control shape? CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  36. 
 
 
 
 Polynomials • Parametric form with polynomials 
 • Control shape? CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  37. 
 
 
 
 Polynomials • Parametric form with polynomials 
 • Control shape? • Monomial coefficients 
 are not intuitive CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  38. Interpolation (1D) • Interpolate control points • Find polynomial 
 with CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  39. Interpolation (1D) • Interpolate control points • Find polynomial 
 with CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  40. Interpolation (1D) • Interpolate control points • Find polynomial 
 with • Solve Vandermonde matrix CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  41. Interpolation (1D) • Interpolate control points • Find polynomial 
 with • Solve CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  42. Interpolation (1D) • Interpolate control points • Find polynomial 
 with • Solve CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  43. Interpolation (1D) • Polynomial fitting can be done explicitly: • Check that • Products are called Lagrange polynomials CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  44. Example of 1D Interpolation CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  45. Recap • Monomial coefficients unintuitive • Lagrange interpolation is better, but there is a global effect • The possible curves are the same: just cubics CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  46. Polynomials form a vector space • You can add and subtract them • You can multiply them by real numbers • These operations follow the usual rules • Associativity, commutativity, inverses for addition • Distributivity for scalar multiplication • Etc. • Anything you can do with vectors in general, you can do with polynomials. CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  47. Monomial basis for cubics: CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  48. Interpolation basis for : CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  49. Remark • Basis change is just a matrix multiplication • We need to find a good basis for intuitively designing curves CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  50. Interpolation in 2D • We now have pairs we want to interpolate: • How to choose ’s at which to specify ? • Parameter space matters! CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  51. Runge’s phenomenon CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  52. Splines • Paste together low-degree polynomials Cubic c i b u c C i b u c C i b u C Cubic CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  53. How do we get smoothness? • With Lagrange polynomials, it’s hard to get tangents to match up CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  54. Hermite Basis • Instead of four points, specify two points and two derivatives: p ( t 0 ) = p 0 p ( t 1 ) = p 1 p 0 ( t 0 ) = m 0 p 0 ( t 1 ) = m 1 Cubic polynomials of the form CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  55. Hermite Basis • Instead of four points, specify two points and two derivatives: CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  56. Catmull-Rom splines • If no tangents are explicitly specified – get them from the input points! CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  57. Next time • Approximating Curves • Bezier splines • B-splines CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

  58. References Fundamentals of Computer Graphics, Fourth Edition 4th Edition by Steve Marschner, Peter Shirley Chapter 15 CSCI-GA.2270-001 - Computer Graphics - Daniele Panozzo

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