Subdivision Surfaces Presentation

advertisement
Subdivision Surfaces in
Character Animation
Chris DeCoro
Presentation of an article
by DeRose, et. Al.
Talk outline
• Introduction
– Motivation and applications
– Previous work
– Additional requirements of animation
•
•
•
•
Semi-sharp Creases
Rendering
Physically-based Modeling
Conclusion
Motivation and Background
• Animation requires smooth surfaces for
visual appeal
• Traditional Approach: NURBS
– However, single patches have limited topology
– Difficult to maintain smoothness during animation
– Often require expensive and inaccurate trimming
• Proposed Solution: Subdivision Surfaces
– Able to represent arbitrary topology
– No trimming
– No seams; always smooth
Previous work
• Catmull-Clark Subdivision
– Input is a quadrilateral mesh, M0
n
n+1
– From mesh M , reaches M through subdivision
– Adds additional vertices to make each quad into 4
subdivided quads
– Limit surface (infinite subdivisions) is smooth
• Infinitely-sharp Creases
–
–
–
–
In some locations, the ideal surface is not smooth
For these applications, we require creases
Sharp edges are manually marked as such
Algorithm uses special subdivision rules
Additional requirements of
animation
• Semi-sharp Creases
– An adjustable intermediate between smooth surfaces and
infinitely sharp creases
• Physical Modeling
– Surfaces pose challenges in representing real world movement
and collisions
– The article will focus on physical modeling of cloth
• Rendering
– NURBS have a direct parameterization for texture mapping
– Subdivision surfaces do not
Talk outline
• Introduction
• Semi-sharp Creases
–
–
–
–
The need for Semi-sharp Creases
Standard Subdivision
Infinitely-sharp Creases
Overall Algorithm
• Rendering
• Physically-based Modeling
• Conclusion
The Need for Semi-sharp Creases
• Most “sharp” edges in nature are smooth at a sufficiently
close distance
– E.g. the edge of a table top
• Often we wish to control the degree of sharpness
– Shown in the illustrations below
Standard Subdivision
• Standard Catmull-Clark Subdivision has three types of
V
E
points in each refined mesh
– Face points
– Vertex points
– Edge points
F
• Face points = centroid of each quad region
• Edge points = 0.25*(vi + ei + fJ-1 + fJ )
• Vertex points =
(n-2)/n*vi + 1/n2*sum(ei) + 1/n2*sum(fi+1)
1/4
1/4
1/4
1/4
1/16
3/8
1/16
1/16
3/8
1/16
1/64
3/32
1/64
9/16
3/32
1/64
3/32
3/32
1/64
Infinitely-Sharp Creases
•
•
•
•
Control vertices and edges are manually tagged as sharp
Face points: same as smooth rule
Edge points: place at midpoint of edge
Vertex points
– One sharp incident edge (dart): same as smooth rule
– Two sharp edges (crease): (e1 + 6vi + e2) / 8
– Three or more sharp edges (corner): do not modify point
Overall Algorithm
• For creases with integer sharpness “s”
– Subdivide using infinitely-sharp rules “s” times
• For creases with non-integer sharpness “s”
– Assume creases with sharpness floor(s) and ceil(s)
– Determine subdivision points for both cases
– Linearly interpolate to compute points for “s”
• After previous steps, and for all elements
– Perform standard (smooth) subdivision to the limit
Talk outline
• Introduction
• Semi-sharp Creases
• Rendering
– Surface texture mapping
– Implementation issues
• Physically-based Modeling
• Conclusion
Texture Mapping
• Textures parameterized onto a 2d plane
– Ideal for NURBS
– Not so ideal for Subdivision Surfaces
• Solution: Subdivide texture coordinates
– Manually apply texture coordinates to the base mesh
– Treat vertex as (x,y,z,s,t) five-tuple
– The texture coordinates are subdivided along with the coordinates
• Can be applied to arbitrary attributes
– Normals, arbitrary shader parameters
Implementation Issues
• The author is working with the Pixar RenderMan system
– Requires geometry be subdivided to sub-pixel sized micropolygons
• Each primitive must bound itself, dice into micropolygons
– Bounding takes advantage of convex hull property
• Each primitive must dice itself into micropolygons
– Locally, surface represents bicubic B-spline patch
– Surface is converted into patch, uses less space (4x4 grid)
– Regular structure makes easier to dice into micropolygons
Talk outline
•
•
•
•
Introduction
Semi-sharp Creases
Rendering
Physically-based Modeling
– Computing cloth energy functional
– Collision determination
• Conclusion
Determining Energy Functional
• Basic properties are specified by
energy functional
– Represents attraction or resistance of
material to deformation
• Catmull-Clark methods become
regular grids
– Ideal for representing woven fabrics
• Energy term represented by:
– E(p1,p2) = 0.5*(|p1-p2|/|p1*-p2*|)2
– p1*, p2* are the positions at rest
• This can be used to represent the
motion of cloth
– Limited motion along thread directions
– Folds freely along the diagonals
Collision Determination
• Several approaches stand out
– Test every object against each other (impractical)
– Three-D spatial partitioning (not ideal)
– Two-D surface partitioning
• Advantages of surface partitioning
– Hierarchy fixed if connectivity does not change
– All data statically allocated, compute in preprocess
• Hierarchy generation through “un-subdividing”
– Pick a candidate edge “e”
– Remove faces adjacent to “e”, merge to “super-face”
– Mark edges adjacent to super-face as non-candidates for one
iteration (for better balancing)
– Store bounding box
• At run time, use precomputed hierarchy to compare
bounding boxes between object and obstacles
Conclusion
• Subdivision surfaces are a better alternative to NURBS
– Always smooth, no seams
– No trimming, greater range of topology
• Semi-sharp Creases allow for enhanced control
– Sharpness can range smooth from none to infinite
• Scalar-field texture maps allow for simplified texturing
– Directly generated from the base mesh
• Successfully integrated into RenderMan
– Thus has shown to be successful in real-world applications
• Collision detection model / Energy functional
– Allows for realistic physics
Download