CS 284: CAGD
Lecture #3 -- Tu 9/05, 2006.
PREVIOUS
< - - - - > CS
284 HOME < - - - - > CURRENT
< - - - - > NEXT
Preparation:
Read: RC pp 49-73.
Lecture Topics: Bézier Curves
-
A very simple and very useful spline ...
-
The defining control points
- Quadratic Case
-
Cubic Case
-
The General Behavior
-
n-th degree Case
-
How much can we do with a curve of a particular degree ? -- See new homework !
Homework Discussion: What can you do with Bézier Curves?
-
What can we do with an eighth-order
Bezier curve (p52)?
-
What order is needed for a G1-smooth loop of turning number 3 ? -->
order
9.
-
What order is needed for a figure-8 shape with C2 point-symmetry ?
--> order
6.
Bernstein Basis Functions
-
Formula (p35)
-
Geometric View (p36)
Understanding the Properties of Bezier Curves
-
Endpoint Interpolation
-
Look at basis functions; check cases for t=0 and t=1.
-
Tangent Condition
-
Look at the basis functions; differentiate.
-
Convex Hull
-
Partition of unity; only interpolation -- not extrapolation.
-
Linear Precision
-
Spacial case of convex hull property.
-
Affine Invariance
-
Splines are based on linear operators.
- Back-to-front Symmetry
- If control polygon is used in reverse order, the same shape results..
-
Variation Diminishing
- Number of line intersections with the control polygon <= intersections with spline
curve.
Drawing Bézier Curves: de Casteljau Algorithm
-
How NOT to evaluate a Bezier curve
-
Finding
curve points by interpolation
-
Recursive linear interpolation (p46).
-
An efficient pipelining scheme, fast and robust!
-
Finding Tangent Directions at various locations
-
Subdivision: Split curve at value t into two segments; find control polygons for both segments.
-
New control points come directly from de Casteljau algorithm.
-
Use of subdivision for clipping to a boundary.
-
Use of subdivision for curve refinement.
Working with Bézier Curves
-
Derivatives
-
Hodograph is just another Bezier curve;
-
its control points have the coordiantes of the original connecting segments.
-
Degree
Elevation
-
Choosing higher-order basis to obtain more control points:
- either to edit fine features into the curve,
- or to match the degrees of adjacent Bezier patches.
-
The general formula for finding the new control points;
-
think about redistributing the needed control points uniformaly along a
straight line.
-
Review of Continuity:
-
Individual segment is always C-infinity continuous.
- It also has G-infinity continuity, unless v=0 at some point;
- then it has a cusp and is only G0 continuous!
Stitching Bezier Curves Together
(more next time ...)
Preview of Lagrange Interpolation
-
Another way to make a smooth interpolating curve.
-
The Goal: To interpolate all data (control) points with ONE function.
-
A Set of basis functions that will achieve this (p.61, eqn 4.2)
-
The concept of "knots" {here: t-values at control points, i.e., at what
"time" do we pass the given points.}
-
Example of the Cubic Lagrange Basis with uniform knots.
-
Effect of changing the knot values: Squeezing "more" of the curve between
some knot pair --> yields bigger bulge.
New Reading Assignment:
Rockwood: pp 59-73 (Lagrange Interpolation)
New Homework Assignment: G1-Stitching of Bezier Curves
In this first programming assignment you will be introduced (gently) to
SLIDE and to the Tcl language. Your actual programming will be less than
ten lines of code (most of the expressions you will need have already been
provided), but it encourages experimentation and thinking.
The goal is to learn how to stitch cubic Bezier segments together to
make a smooth, pleasing-looking, interpolating curve that behaves well
even for rather ragged control polygons with irregularly spaced control
points (like the example we did in class by hand).
Your assignment is to find a robust expression for the placement for
the inner control points of each Bezier segment, involving only information
from the nearest neighbor points, and which guarantees a G1-continuous
overall curve.
DUE: Sept. 12, 2006, 2:10pm.
-- Hand in:
- Window snapshot showing your best solution;
- The formula you used to place the inner control points;
- A one paragraph discussion of your approach, and what you learned from
it;
- Any other comments you would like to make.
The code that you should modify and execute, can be found at:
http://www.cs.berkeley.edu/~sequin/CS284/CODE/pa1.slf
Information on how to install SLIDE on your computer can be found at:
http://www.cs.berkeley.edu/~ug/slide/viewer/slide2004/README
PREVIOUS
< - - - - > CS
284 HOME < - - - - > CURRENT
< - - - - > NEXT
Page Editor: Carlo H. Séquin