Curves And Surfaces - Carnegie Mellon School Of Computer Science

1y ago
16 Views
3 Downloads
668.41 KB
39 Pages
Last View : 22d ago
Last Download : 3m ago
Upload by : Maxine Vice
Transcription

15-462 Computer Graphics ILecture 9Curves and SurfacesParametric RepresentationsCubic Polynomial FormsHermite CurvesBezier Curves and Surfaces[Angel 10.1-10.6]February 11, 2003Frank PfenningCarnegie Mellon Universityhttp://www.cs.cmu.edu/ fp/courses/graphics/

Goals How do we draw surfaces?– Approximate with polygons– Draw polygons How do we specify a surface?– Explicit, implicit, parametric How do we approximate a surface?– Interpolation (use only points)– Hermite (use points and tangents)– Bezier (use points, and more points for tangents) Next lecture: splines, realization in OpenGL02/11/200315-462 Graphics I2

Explicit Representation Curve in 2D: y f(x)Curve in 3D: y f(x), z g(x)Surface in 3D: z f(x,y)Problems:– How about a vertical line x c as y f(x)?– Circle y § (r2 – x2)1/2 two or zero values for x Too dependent on coordinate system Rarely used in computer graphics02/11/200315-462 Graphics I3

Implicit Representation Curve in 2D: f(x,y) 0– Line: ax by c 0– Circle: x2 y2 – r2 0 Surface in 3d: f(x,y,z) 0– Plane: ax by cz d 0– Sphere: x2 y2 z2 – r2 0 f(x,y,z) can describe 3D object:– Inside: f(x,y,z) 0– Surface: f(x,y,z) 0– Outside: f(x,y,z) 002/11/200315-462 Graphics I4

Algebraic Surfaces Special case of implicit representationf(x,y,z) is polynomial in x, y, zQuadrics: degree of polynomial · 2Render more efficiently than arbitrary surfacesImplicit form often used in computer graphicsHow do we represent curves implicitly?02/11/200315-462 Graphics I5

Parametric Form for Curves Curves: single parameter u (e.g. time)x x(u), y y(u), z z(u)Circle: x cos(u), y sin(u), z 0Tangent described by derivative Magnitude is “velocity”02/11/200315-462 Graphics I6

Parametric Form for Surfaces Use parameters u and vx x(u,v), y y(u,v), z z(u,v)Describes surface as both u and v varyPartial derivatives describe tangent plane ateach point p(u,v) [x(u,v) y(u,v) z(u,v)]T02/11/200315-462 Graphics I7

Assessment of Parametric Forms Parameters often have natural meaning Easy to define and calculate– Tangent and normal– Curves segments (for example, 0 · u · 1)– Surface patches (for example, 0 · u,v · 1)02/11/200315-462 Graphics I8

Parametric Polynomial Curves Restrict x(u), y(u), z(u) to be polynomial in u Fix degree n Each ck is a column vector02/11/200315-462 Graphics I9

Parametric Polynomial Surfaces Restrict x(u,v), y(u,v), z(u,v) to be polynomial offixed degree n Each cik is a 3-element column vector Restrict to simple case where 0 · u,v · 102/11/200315-462 Graphics I10

Approximating Surfaces Use parametric polynomial surfaces Important concepts:––––Join points for segments and patchesControl points to interpolateTangents and smoothnessBlending functions to describe interpolation First curves, then surfaces02/11/200315-462 Graphics I11

Outline Parametric RepresentationsCubic Polynomial FormsHermite CurvesBezier Curves and Surfaces02/11/200315-462 Graphics I12

Cubic Polynomial Form Degree 3 appears to be a useful compromise Curves: Each ck is a column vector [ckx cky ckz]T From control information (points, tangents)derive 12 values ckx, cky, ckz for 0 · k · 3 These determine cubic polynomial form Later: how to render02/11/200315-462 Graphics I13

Interpolation by Cubic Polynomials Simplest case, although rarely used Curves:– Given 4 control points p0, p1, p2, p3– All should lie on curve: 12 conditions, 12 unknowns Space 0 · u · 1 evenlyp0 p(0), p1 p(1/3), p2 p(2/3), p3 p(1)02/11/200315-462 Graphics I14

Equations to Determine ck Plug in values for u 0, 1/3, 2/3, 1Note:pk and ckare vectors!02/11/200315-462 Graphics I15

Interpolating Geometry Matrix Invert A to obtain interpolating geometry matrix02/11/200315-462 Graphics I16

Joining Interpolating Segments Do not solve degree n for n points Divide into overlap sequences of 4 points p0, p1, p2, p3 then p3, p4, p5, p6, etc. At join points– Will be continuous (C0 continuity)– Derivatives will usually not match (no C1 continuity)02/11/200315-462 Graphics I17

Blending Functions Make explicit, how control points contribute Simplest example: straight line with controlpoints p0 and p3 p(u) (1 – u) p0 u p3 b0(u) 1 – u, b3(u) u1 b0(u)b3(u)u102/11/200315-462 Graphics I18

Blending Polynomials for Interpolation Each blending polynomial is a cubic Solve (see [Angel, p. 427]):02/11/200315-462 Graphics I19

Cubic Interpolation Patch Bicubic surface patch with 4 4 control pointsNote: each cik is3 column vector(48 unknowns)[Angel, Ch. 10.4.2]02/11/200315-462 Graphics I20

Outline Parametric RepresentationsCubic Polynomial FormsHermite CurvesBezier Curves and Surfaces02/11/200315-462 Graphics I21

Hermite Curves Another cubic polynomial curve Specify two endpoints and their tangents02/11/200315-462 Graphics I22

Deriving the Hermite Form As before Calculate derivative Yields02/11/200315-462 Graphics I23

Summary of Hermite Equations Write in matrix form Remember pk and p’k and ck are vectors! Let q [p0 p3 p’0 p’3]T and invert to findHermite geometry matrix MH satisfying02/11/200315-462 Graphics I24

Blending Functions Explicit Hermite geometry matrix Blending functions for u [1 u u2 u3]T02/11/200315-462 Graphics I25

Join Points for Hermite Curves Match points and tangents (derivates) Much smoother than point interpolationHow to obtain the tangents?Skip Hermite surface patchMore widely used: Bezier curves and surfaces02/11/200315-462 Graphics I26

Parametric Continuity Matching endpoints (C0 parametric continuity) Matching derivatives (C1 parametric continuity)02/11/200315-462 Graphics I27

Geometric Continuity For matching tangents, less is required G1 geometric continuity Extends to higher derivatives02/11/200315-462 Graphics I28

Outline Parametric RepresentationsCubic Polynomial FormsHermite CurvesBezier Curves and Surfaces02/11/200315-462 Graphics I29

Bezier Curves Widely used in computer graphics Approximate tangents by using control points02/11/200315-462 Graphics I30

Equations for Bezier Curves Set up equations for cubic parametric curve Recall: Solve for ck02/11/200315-462 Graphics I31

Bezier Geometry Matrix Calculate Bezier geometry matrix MB Have C0 continuity, not C1 continuity Have C1 continuity with additional condition02/11/200315-462 Graphics I32

Blending Polynomials Determine contribution of each control pointSmooth blendingpolynomials02/11/200315-462 Graphics I33

Convex Hull Property Bezier curve contained entirely in convex hull ofcontrol points Determined choice of tangent coefficient (?)02/11/200315-462 Graphics I34

Bezier Surface Patches Specify Bezier patch with 4 4 control points Bezier curves along the boundary02/11/200315-462 Graphics I35

Twist Inner points determine twist at corner Flat means p00, p10, p01, p11 in one plane ( 2p/ u v)(0,0) 002/11/200315-462 Graphics I36

Summary Parametric RepresentationsCubic Polynomial FormsHermite CurvesBezier Curves and Surfaces02/11/200315-462 Graphics I37

Preview B-Splines: more continuity (C2) Non-uniform B-splines (“heavier” points) Non-uniform rational B-splines (NURBS)– Rational functions instead of polynomials– Based on homogeneous coordinates Rendering and recursive subdivision Curves and surfaces in OpenGL02/11/200315-462 Graphics I38

Announcements Handing back Assignment 2 ThursdayModel solution coming soonAssignment 3 due a week from ThursdayMovie from Assignment 1!Thursday: Texture Mapping [Ian Graham]Next Tuesday: Splines02/11/200315-462 Graphics I39

Hermite Curves Bezier Curves and Surfaces [Angel 10.1-10.6] Parametric Representations Cubic Polynomial Forms Hermite Curves Bezier Curves and Surfaces . Hermite geometry matrix M H satisfying. 02/11/2003 15-462 Graphics I 25 Blending FunctionsBlending Functions Explicit Hermite geometry matrix

Related Documents:

CMMI Appraisal Program The Software Engineering Institute is a federally funded research and development center sponsored by the U.S. Department of Defense and operated by Carnegie Mellon University CMMI, Capability Maturity Model and Carnegie Mellon are re gistered in the U.S. Patent and Trademark Office by Carnegie Mellon University

CMMI Appraisal Program The Software Engineering Institute is a federally funded research and development center sponsored by the U.S. Department of Defense and operated by Carnegie Mellon University CMMI and Carnegie Mellon are registered in the U.S. Patent and Trademark Office by Carnegie Mellon University

Sebastian Montiel, Antonio Ros, \Curves and surfaces", American Mathematical Society 1998 Alfred Gray, \Modern di erential geometry of curves and surfaces", CRC Press 1993 5. 6 CHAPTER 1. CURVES . Contents: This course is about the analysis of curves and surfaces in 2-and 3-space using the tools of calculus and linear algebra. Emphasis will

CMMI Appraisal Program The Software Engineering Institute is a federally funded research and development center sponsored by the U.S. Department of Defense and operated by Carnegie Mellon University CMMI, Capability Maturity Model and Carnegie Mellon are registered in the U.S. Patent and Trademark Office by Carnegie Mellon University

Impact from Innovation: Carnegie Mellon University's Role as a Local and Global Economic Engine Final Report iv EXECUTIVE SUMMARY World-class institutions of higher education such as Carnegie Mellon University (CMU) are widely known for their academic and research contributions. They are also major contributors to their local economies.

Carnegie Mellon is registered in the U.S. Patent and Trademark Office by Carnegie Mellon Univer-sity. DM18-0396. CMU/SEI-2019-TR-003 SOFTWARE ENGINEERING INSTITUTE CARNEGIE MELLON UNIVERSITY i . 3 Shared Responsibility Model in Cloud Computing 5 4 Important Practices 7 4.1 Perform Due Diligence 7 4.1.1 Planning 7 4.1.2 Development and .

this carnegie mellon university and software engineering institute material is furnished on an "as-is" basis. carnegie mellon university makes no warran- ties of any kind, either expressed or implied, as to any matter including, but not limited to, warranty of fitness for purpose or merchan1tbility, exclusivity, or

An informative and interactive one-day workshop. No dance experience necessary, but a fun outlook will be a mandate. (contact local churches and temples to see if their adult singles groups are interested in co-sponoring) Introduction to Free Weights for Women Women will learn the basics of working out with free weights with emphasis on safety, form and fun. Any questions or concerns about .