parametric surface patches

parametric surface patches
1
implicit representation
implicit surface representation
f (P) = 0
e.g. sphere: f (P)
= 0 → x
2
+ y
2
+ z
2
2
− r
= 0
2
parametric representation
parametric surface representation
P(u) = (f x (u), fy (u), f z (u))
e.g. sphere: P(u)
= (rcos ϕsin θ, rsin ϕsin θ, rcos θ)
3
parametric representation
goals when defining f
smoothness, efficiency, local control
same as curves
(1) combine curves to obtain surfaces
easy for simple solids, but not general
(2) extend parametric curves to surface patches
general formulation
used heavily in CAD
4
surfaces from curves
example: extrude curve C(u) in XY-plane along Z-axis
P(u, v) = (Cx (u), Cy (u), v)
example: revolve curve C(u) in YZ-plane about Z-axis
P(u, v) = (Cy (u) cos(v), Cy (u) sin(v), Cz (u))
5
patches
6
patches
spline curves: 1D blending functions
P(t) = ∑ bi (t)Pi
i
surface patches: 2D blending functions
cross product of 1D blending functions
P(u, v) = ∑ bij (u, v)Pij
ij
bij (u, v) = bi (u)bj (v)
7
patches
bicubic Bezier patches
8
patches
joining is hard
9
other patch functions
just like curves
uniform, non-uniform
non-uniform rational B-splines (NURBS)
ratios of B-splines
invariance under perspective
can represent conic sections exactly
often used in 3D
10
rendering parametric surfaces
11
rendering parametric surfaces
tesselation: approximate surfaces with triangles/quads
meshes are efficient to draw in hardware and software
more faces to provide better approximation
uniform tesselation: split (u, v) intervals uniformly
fast to compute and simple to implement
generates many segments
adaptive tesselation: split recursively until good enough
Bezier patches can use De Castaljeu
12
uniform tesselation
split in K
× K
points uniformly at
(uk1 , vk2 ) = (1/k1 , 1/k2 )
tesselate into quads by creating a K
set vertices to P(uk
1
× K
quad grid
, vk2 )
join vertices to avoid holes if function wraps (e.g. cylinder)
normals
evaluate analytically if possible (e.g. sphere)
or evaluate by computing partial derivatives
n = ∂P/∂u × ∂P/∂v
or smooth mesh by averaging face normals over vertices
13