12/9/ :28 UML Graphics II B-Splines NURBS Session 3A
22/9/ :28 UML B-splines Suppose you wanted C 0, C 1 and C 2 continuity at curve boundaries. Use all four control points to determine boundary continuities and only require that the curve pass “close” to the points.
32/9/ :28 UML B-splines: Sharing of Control Points
42/9/ :28 UML B-splines: Using continuity requirements to compute geometry matrix/blending functions C 0 continuity here requires:
52/9/ :28 UML B-splines: Using continuity requirements to compute geometry matrix/blending functions
62/9/ :28 UML B-splines: Using continuity requirements to compute geometry matrix/blending functions Similarly, the C 1 and C 2 continuity conditions give:
72/9/ :28 UML B-spline blending functions 0 1
82/9/ :28 UML B-splines: Local versus global parameter
92/9/ :28 UML B-splines: Recursively defined basis functions For any “knot vector”: Order i
102/9/ :28 UML First order basis functions:
112/9/ :28 UML Second order basis functions:
122/9/ :28 UML Knot Vectors Only Requirement: Image: David Rogers
132/9/ :28 UML Definition of B Spline Curve Order of the spline Number of control points Number of knots in knot vector * * Notation according to D.F. Rogers
142/9/ :28 UML Knot Vectors: Open, Uniform Result: spline passes through end control vertices Image: David Rogers
152/9/ :28 UML Building Up Basis Functions Image: David Rogers
162/9/ :28 UML Methods of Control 0 Change number and/or position of control vertices 0 Change order k 0 Change type of knot vector -Open uniform -Open non uniform 0 Use multiple coincident control vertices 0 Use multiple internal knot values Image: David Rogers
172/9/ :28 UML Control: Change Order Image: David Rogers
182/9/ :28 UML Control: Non Uniform Knot Vectors Image: David Rogers
192/9/ :28 UML Control: Knot Vector Type Image: David Rogers
202/9/ :28 UML Control: Multiple Coincident Vertices Image: David Rogers
212/9/ :28 UML Control: Duplicate Knot Values Image: David Rogers
222/9/ :28 UML Rational B-Splines (NURBS) Equivalency between Homogeneous representations: Doing the perspective division gives: Interpreted as “weighting factor” for control vertices
232/9/ :28 UML NURBS Effect of weighting factor Image: David Rogers
242/9/ :28 UML Drawing NURBS in OpenGL GLUnurbsObj *curveName; curveName = gluNewNurbsRenderer(); gluBeginCurve (curveName); gluNurbsCurve (curveName, nknots, *knotVector, stride, *ctrlPts, degParam, GL_MAP1_VERTEX_3); gluEndCurve (curveName); See OpenGL Programming Guide Ch. 12 for details of using the glu NURBS interface
252/9/ :28 UML NURBS: Code Example 120 goto 120
262/9/ :28 UML Extending from Curves to Surfaces Cartesian product of B-Spline basis functions Order can be different for u and v directions