19/13/2015 10:20 UML Graphics II 91.547 Parametric Curves and Surfaces Session 3.

Slides:



Advertisements
Similar presentations
Lecture Notes #11 Curves and Surfaces II
Advertisements

Cubic Curves CSE167: Computer Graphics Instructor: Steve Rotenberg UCSD, Fall 2006.
ICS 415 Computer Graphics Bézier Splines (Chapter 8)
Overview June 9- B-Spline Curves June 16- NURBS Curves June 30- B-Spline Surfaces.
CS 445/645 Fall 2001 Hermite and Bézier Splines. Specifying Curves Control Points –A set of points that influence the curve’s shape Knots –Control points.
© University of Wisconsin, CS559 Spring 2004
Jehee Lee Seoul National University
1 Curves and Surfaces. 2 Representation of Curves & Surfaces Polygon Meshes Parametric Cubic Curves Parametric Bi-Cubic Surfaces Quadric Surfaces Specialized.
Slide 127 October 1999CS Computer Graphics (Top Changwatchai) Review of Spline Concepts Sections 10-6 to in Hearn & Baker Splines can be 2D.
Lecture 29 of 42 Bezier Curves and Splines Wednesday, 02 April 2008
Informationsteknologi Monday, December 10, 2007Computer Graphics - Class 161 Today’s class Curve fitting Evaluators Surfaces.
09/04/02 Dinesh Manocha, COMP258 Bezier Curves Interpolating curve Polynomial or rational parametrization using Bernstein basis functions Use of control.
1 Dr. Scott Schaefer The Bernstein Basis and Bezier Curves.
Designing Parametric Cubic Curves Ed Angel Professor of Computer Science, Electrical and Computer Engineering, and Media Arts University of New Mexico.
Bezier and Spline Curves and Surfaces Ed Angel Professor of Computer Science, Electrical and Computer Engineering, and Media Arts University of New Mexico.
Modelling: Curves Week 11, Wed Mar 23
RASTER CONVERSION ALGORITHMS FOR CURVES: 2D SPLINES 2D Splines - Bézier curves - Spline curves.
University of British Columbia CPSC 414 Computer Graphics © Tamara Munzner 1 Curves Week 13, Mon 24 Nov 2003.
Bezier and Spline Curves and Surfaces CS4395: Computer Graphics 1 Mohan Sridharan Based on slides created by Edward Angel.
COEN Computer Graphics I
Designing Parametric Cubic Curves
Splines III – Bézier Curves
Curves and Surfaces (cont’) Amy Zhang. Conversion between Representations  Example: Convert a curve from a cubic B-spline curve to the Bézier form:
Curve Modeling Bézier Curves
11/19/02 (c) 2002, University of Wisconsin, CS 559 Last Time Many, many modeling techniques –Polygon meshes –Parametric instancing –Hierarchical modeling.
1 Introduction to Computer Graphics with WebGL Ed Angel Professor Emeritus of Computer Science Founding Director, Arts, Research, Technology and Science.
A D V A N C E D C O M P U T E R G R A P H I C S CMSC 635 January 15, 2013 Spline curves 1/23 Curves and Surfaces.
V. Space Curves Types of curves Explicit Implicit Parametric.
Introduction to Computer Graphics with WebGL
Quadratic Surfaces. SPLINE REPRESENTATIONS a spline is a flexible strip used to produce a smooth curve through a designated set of points. We.
June D Object Representation Shmuel Wimer Bar Ilan Univ., School of Engineering.
1 Introduction to Computer Graphics with WebGL Ed Angel Professor Emeritus of Computer Science Founding Director, Arts, Research, Technology and Science.
Curves and Surfaces Chapter 10. CS 480/680 2Chapter 9 -- Hierarchical Models Introduction: Introduction: Until now we have worked with flat entities such.
Parametric Surfaces Define points on the surface in terms of two parameters Simplest case: bilinear interpolation s t s x(s,t)x(s,t) P 0,0 P 1,0 P 1,1.
COLLEGE OF ENGINEERING UNIVERSITY OF PORTO COMPUTER GRAPHICS AND INTERFACES / GRAPHICS SYSTEMS JGB / AAS Representation of Curves and Surfaces Graphics.
Representation of Curves & Surfaces Prof. Lizhuang Ma Shanghai Jiao Tong University.
04/18/02(c) 2002 University of Wisconsin Last Time Hermite Curves Bezier Curves.
Curves: ch 4 of McConnell General problem with constructing curves: how to create curves that are “smooth” CAD problem Curves could be composed of segments.
Rendering Curves and Surfaces Ed Angel Professor of Computer Science, Electrical and Computer Engineering, and Media Arts University of New Mexico 1 Angel:
11/6/ :55 Graphics II Introduction to Parametric Curves and Surfaces Session 2.
Review CSE167: Computer Graphics Instructor: Steve Rotenberg UCSD, Fall 2005.
Parametric Curves & Surfaces
Computing & Information Sciences Kansas State University Lecture 31 of 42CIS 636/736: (Introduction to) Computer Graphics Lecture 32 of 42 Wednesday, 11.
11/26/02(C) University of Wisconsin Last Time BSplines.
Designing Parametric Cubic Curves 1. 2 Objectives Introduce types of curves ­Interpolating ­Hermite ­Bezier ­B-spline Analyze their performance.
1 Introduction to Computer Graphics with WebGL Ed Angel Professor Emeritus of Computer Science Founding Director, Arts, Research, Technology and Science.
1 Graphics CSCI 343, Fall 2015 Lecture 34 Curves and Surfaces III.
1 Introduction to Computer Graphics with WebGL Ed Angel Professor Emeritus of Computer Science Founding Director, Arts, Research, Technology and Science.
CS 450: Computer Graphics PARAMETRIC SPLINES AND SURFACES
Splines Sang Il Park Sejong University. Particle Motion A curve in 3-dimensional space World coordinates.
Curves University of British Columbia CPSC 314 Computer Graphics Jan-Apr 2013 Tamara Munzner.
CS552: Computer Graphics Lecture 19: Bezier Curves.
Object Modeling: Curves and Surfaces CEng 477 Introduction to Computer Graphics.
Slide 1Lecture Fall ‘00 Surface Modeling Types: Polygon surfaces Curved surfaces Volumes Generating models: Interactive Procedural.
Introduction to Parametric Curve and Surface Modeling.
© University of Wisconsin, CS559 Spring 2004
Representation of Curves & Surfaces
Chapter 10-2: Curves.
CSE 167 [Win 17], Lecture 9: Curves 1 Ravi Ramamoorthi
Parametric Curves.
© University of Wisconsin, CS559 Fall 2004
© University of Wisconsin, CS559 Fall 2004
Rendering Curves and Surfaces
© University of Wisconsin, CS559 Spring 2004
Implicit Functions Some surfaces can be represented as the vanishing points of functions (defined over 3D space) Places where a function f(x,y,z)=0 Some.
UNIT-5 Curves and Surfaces.
Three-Dimensional Object Representation
Introduction to Parametric Curve and Surface Modeling
Type to enter a caption. Computer Graphics Week 10 Lecture 2.
Overview June 9- B-Spline Curves June 16- NURBS Curves
Presentation transcript:

19/13/ :20 UML Graphics II Parametric Curves and Surfaces Session 3

29/13/ :20 UML Parametric Curves and Surfaces: Key Concepts Point Curve, SurfaceCollection of points Parametric Representation (for a curve)

39/13/ :20 UML Parametric Curves and Surfaces Key Concepts, contd. Multiplying a point by a scalar:Scaling the representation Polynomial Control Points Set of (degree+1) points that bear some relation to the desired curve or surface Basis Functions Set of (degree + 1) polynomials that, when multiplied by the corresponding control points, produce the curve or surface

49/13/ :20 UML Continuity Considerations: C0 & C1 Continuity

59/13/ :20 UML How do we insure C 0 and C 1 continuity?

69/13/ :20 UML Bezier Curves: 1. Require interpolation at the endpoints of the curve: 2. Require that the line segments P 0 P 1 and P 3 P 2 match the first derivative of the curve at 0 and 1.

79/13/ :20 UML Calculating the Bezier Geometry Matrix

89/13/ :20 UML Calculating the Bezier Geometry Matrix

99/13/ :20 UML Bezier Blending Functions where This can be expressed:

109/13/ :20 UML Bezier Blending Functions:

119/13/ :20 UML Convex Hull Property: Curve must lie within this region known as “convex hull” of the control points.

129/13/ :20 UML Further look at the Bezier blending functions: These are an instance of the Bernstein Polynomials for k=3. Factoring the blending functions gives:

139/13/ :20 UML Bezier Curves: Code Example 120 goto 120

149/13/ :20 UML An interesting geometric construction

159/13/ :20 UML Recursive subdivision of Bezier curves

169/13/ :20 UML Bezier surface patch Convex hull of patch

179/13/ :20 UML Bezier surface patch Corner boundary conditions Four equations for each corner gives 16 total. Patch must interpolate the corner. Defines derivative in u direction. Defines derivative in v direction. “Twist”

189/13/ :20 UML Rendering the Bezier patch by recursive subdivision First subdivide curves of constant v. Connect new control points to form new curves. Finally subdivide these curves to form 4 new patches.

199/13/ :20 UML Recursive subdivision of Bezier curves

209/13/ :20 UML The Utah Teapot: 32 Bezier Patches

219/13/ :20 UML Utah Teapot: Polygon Representation

229/13/ :20 UML Rendering the Teapot

239/13/ :20 UML Conversion between curve representations Given a cubic Bezier curve expressed in terms of the Bezier geometry matrix, M B : The same curve can be expressed in terms of another polynomial basis with matrix M and matrix of control points q. Solving for q gives:

249/13/ :20 UML Conversion between curve representations: an example Suppose you have a matrix of four control points, q and a cubic interpolating those points q(u). The curve is obtained by the interpolating geometry matrix M I : where We want to find p such that:

259/13/ :20 UML Drawing Bezier curves and surfaces: Evaluators Evaluator Control Points Parameter Generation glMap1{fd}() glMap2{fd}() glEvalCoord1{fd}() glEvalCoord2{fd}() Parameter(s) Curve/surface value Establish Evaluator: Evaluate Points:

269/13/ :20 UML One Dimensional Evaluators Void glMap1{fd](GLenum target, TYPE u1, TYPE u2, Glint stride,Glint order, TYPE *points); target: specifies what the control points represent u1: beginning parameter value u2: end parameter value stride: number of values in each block of control point storage order: order of the Bezier curve (degree+1) *points: pointer to array of control points

279/13/ :20 UML One Dimensional Evaluators: target parameter GL_MAP_VERTEX_3x,y,z vertex coords. GL_MAP_VERTEX_4x,y,z,w vertex coords GL_MAP1_INDEXcolor index GL_MAP1_COLOR_4RGBA GL_MAP2_NORMALnormal coordinates GL_MAP1_TEXTURE_COORD_1s texture coords. GL_MAP1_TEXTURE_COORD_2s,t texture coords. GL_MAP1_TEXTURE_COORD_3s,t,r texture coords. GL_MAP1_TEXTURE_COORD_4s,t,r,q texture coords.

289/13/ :20 UML One Dimensional Evaluators: Code Example 120 goto 120 ?

299/13/ :20 UML Mesh Generation: One Dimensional void glMapGrid1{fd} (Glint n, TYPE u1, TYPE u2); Defines a grid that goes from u1 to u2 in n evenly spaced steps. void glEvalMesh1 (GLenum mode, GLint p1, Glint p2); mode is either GL_POINT or GL_LINE depending on whether you want to draw individual points or connected lines. p1, p2 are the grid values between which the mesh is to be evaluated

309/13/ :20 UML Two Dimensional Evaluators Void glMap2{fd](GLenum target, TYPE u1, TYPE u2, Glint ustride,Glint uorder, TYPE v1, TYPE v2, GLint vstride, Glint vorder, TYPE *points); target: specifies what the control points represent u1, v1: beginning parameter value u2, v2: end parameter value stride: number of values in each block of control point storage order: order of the Bezier curve (degree+1) *points: pointer to array of control points

319/13/ :20 UML Mesh Generation: Two Dimensional void glMapGrid2{fd} (GLint nu, TYPE u1, TYPE u2 GLint nv, TYPE v1, TYPE v2); Defines a two dimensional grid that goes from u1 to u2 in nu evenly spaced steps and from v1 to v2 in nv evenly spaced steps. void glEvalMesh2 (GLenum mode, GLint p1, GLint p2, GLint q1, GLint q2); mode is either GL_POINT, GL_LINE, or GL_FILL depending on whether you want to draw individual points, connected lines, or a filled mesh. p1, p2, q1, q2 are the grid values between which the mesh is to be evaluated

329/13/ :20 UML Two Dimensional Evaluators: Code Examples 120 goto 120