Las Time? Adjacency Daa Srucures Spline Curves Geomeric & opologic informaion Dynamic allocaion Efficiency of access Mesh Simplificaion edge collapse/verex spli geomorphs progressive ransmission view-dependen refinemen Color Inerpolaion Inerpolae colors of he 3 verices Linear inerpolaion, barycenric coordinaes Inerpolaing Color & Normals in OpenGL Limiaions of Polygonal Models Some Modeling Tools & Definiions Wha's a Spline? Linear Inerpolaion Inerpolaion Curves vs. Approximaion Curves Spline (NURBS) glshademodel (GL_SMOOTH); glbegin(gl_triangles); glcolor3f(1.0,0.0,0.0); glverex3f( ); glcolor3f(0.0,1.0,0.0); glverex3f( ); glcolor3f(0.0,0.0,1.0); glverex3f( ); glend(); Normal Inerpolaion From OpenGL Reference Manual: Smooh shading, he defaul, causes he compued colors of verices o be inerpolaed as he primiive is raserized, ypically assigning differen colors o each resuling pixel fragmen. Fla shading selecs he compued color of jus one verex and assigns i o all he pixel fragmens generaed by raserizing a single primiive. In eiher case, he compued color of a verex is he resul of lighing if lighing is enabled, or i is he curren color a he ime he verex was specified if lighing is disabled. ray racing scan conversion fla shading glbegin(gl_triangles); glnormal3f( ); glverex3f( ); glnormal3f( ); glverex3f( ); glnormal3f( ); glverex3f( ); glend(); scan conversion gouraud shading 1
Gouraud Shading Insead of shading wih he normal of he riangle, we ll shade he verices wih he average normal and inerpolae he shaded color across each face Inerpolaing Color & Normals in OpenGL Limiaions of Polygonal Models Some Modeling Tools & Definiions Wha's a Spline? Linear Inerpolaion Inerpolaion Curves vs. Approximaion Curves Spline (NURBS) How do we compue Average Normals? Is i expensive?? Limiaions of Polygonal Meshes Planar faces (& silhouees) Fixed resoluion Deformaion is difficul No naural parameerizaion (for exure mapping) Gouraud no always good enough Sill low, fixed resoluion (missing fine deails) Sill have polygonal silhouees Inersecion deph is planar (e.g. ray racing visualizaion) Collisions problems for simulaion Solid Texuring problems... Some Non-Polygonal Modeling Tools Coninuiy definiions: Exrusion Spline Surfaces/Paches Surface of Revoluion Quadrics and oher implici polynomials C 0 coninuous curve/surface has no breaks/gaps/holes G 1 coninuous angen a join has same direcion C 1 coninuous curve/surface derivaive is coninuous angen a join has same direcion and magniude C n coninuous curve/surface hrough n h derivaive is coninuous imporan for shading Shape Opimizaion Using Reflecion Lines, Tosun e al., 2007 2
Quesions? Inerpolaing Color & Normals in OpenGL Limiaions of Polygonal Models Some Modeling Tools & Definiions Wha's a Spline? Linear Inerpolaion Inerpolaion Curves vs. Approximaion Curves Spline (NURBS) Definiion: Wha's a Spline? Inerpolaion Curves / Splines Smooh curve defined by some conrol poins Moving he conrol poins changes he curve Inerpolaion (approximaion) (approximaion) www.abm.org Inerpolaion Curves Curve is consrained o pass hrough all conrol poins Given poins P 0, P 1,... P n, find lowes degree polynomial which passes hrough he poins x() = a n-1 n-1 +... + a 2 2 + a 1 + a 0 y() = b n-1 n-1 +... + b 2 2 + b 1 + b 0 Linear Inerpolaion Simples "curve" beween wo poins Q() = Spline Basis Funcions a.k.a. Blending Funcions 3
Inerpolaion vs. Approximaion Curves Inerpolaion vs. Approximaion Curves Inerpolaion Curve over consrained los of (undesirable?) oscillaions Inerpolaion curve mus pass hrough conrol poins Approximaion curve is influenced by conrol poins Approximaion Curve more reasonable? Quesions? Inerpolaing Color & Normals in OpenGL Limiaions of Polygonal Models Some Modeling Tools & Definiions Wha's a Spline? Linear Inerpolaion Inerpolaion Curves vs. Approximaion Curves Spline (NURBS) Cubic Curve Cubic Curve 4 conrol poins Curve passes hrough firs & las conrol poin Curve is angen a P 1 o (P 2 -P 1 ) and a P 4 o (P 4 -P 3 ) de Caseljau's algorihm for consrucing curves A curve is bounded by he convex hull of is conrol poins. 4
Cubic Curve Connecing Cubic Curves Asymmeric: Curve goes hrough some conrol poins bu misses ohers Bernsein Polynomials How can we guaranee C 0 coninuiy? How can we guaranee G 1 coninuiy? How can we guaranee C 1 coninuiy? Can guaranee higher C 2 or higher coninuiy Connecing Cubic Curves Where is his curve C 0 coninuous? G 1 coninuous? C 1 coninuous? Wha s he relaionship beween: he # of conrol poins, and he # of cubic subcurves? Higher-Order Curves > 4 conrol poins Bernsein Polynomials as he basis funcions Every conrol poin affecs he enire curve No simply a local effec More difficul o conrol for modeling Quesions? Inerpolaing Color & Normals in OpenGL Limiaions of Polygonal Models Some Modeling Tools & Definiions Wha's a Spline? Linear Inerpolaion Inerpolaion Curves vs. Approximaion Curves Spline (NURBS) 5
Cubic s 4 conrol poins Locally cubic Curve is no consrained o pass hrough any conrol poins Cubic s Ieraive mehod for consrucing s A curve is also bounded by he convex hull of is conrol poins. Shirley, Fundamenals of Compuer Graphics Cubic s Connecing Cubic Curves Can be chained ogeher Beer conrol locally (windowing) Connecing Cubic Curves Curve Conrol Poins Wha s he relaionship beween he # of conrol poins, and he # of cubic subcurves? Defaul wih Disconinuiy Repea inerior conrol poin which passes hrough end poins Repea end poins 6
is no he same as is no he same as Relaionship o he conrol poins is differen Convering beween & Convering beween & original conrol poins as new conrol poins o mach Using he basis funcions: new conrol poins o mach original conrol poins as NURBS (generalized s) : uniform cubic NURBS: Non-Uniform Raional non-uniform = differen spacing beween he blending funcions, a.k.a. knos raional = raio of polynomials (insead of cubic) Nea Bezier Spline Trick A Bezier curve wih 4 conrol poins: P 0 P 1 P 2 P 3 Can be spli ino 2 new Bezier curves: P 0 P 1 P 2 P 3 P 3 P 4 P 5 P 3 A curve is bounded by he convex hull of is conrol poins. 7
Quesions? Readings for (pick one) "Free-form deformaion of solid geomeric models", Sederberg & Parry, SIGGRAPH 1986 "Teddy: A Skeching Inerface for 3D Freefrom Design", Igarashi e al., SIGGRAPH 1999 Readings for Friday (1/25) pick one DeRose, Kass, & Truong, "Subdivision Surfaces in Characer Animaion", SIGGRAPH 1998 Pos a commen or quesion on he LMS discussion by 10am on Friday 8