您好,欢迎访问三七文档
当前位置:首页 > 商业/管理/HR > 管理学资料 > 第十六讲 Curves and Surfaces (I)
计算机图形学讲义-16CurvesandSurfaces(I)Basedon[EA],Chapter10.姜明北京大学数学科学学院更新时间2020年1月23日星期四12时8分45秒计算机图形学讲义-16Introduction•Incomputergraphics,flatobjectsarepopularinthisvirtualworld–Graphicsystemscanrenderthemathighrates.•Weneedmethodstomodelcurvedobjects.计算机图形学讲义-16Outline•RepresentationofCurvesandSurfaces•DesignCriteria•ParametricCubicPolynomialCurves•CubicInterpolatingPolynomial计算机图形学讲义-16RepresentationofCurvesandSurfaces•Threemajorwaysofobjectrepresentation–ExplicitRepresentation–ImplicitRepresentations–ParametricForm•PolynomialRepresentations–ParametricPolynomialCurves–ParametricPolynomialSurfaces计算机图形学讲义-16ExplicitRepresentation•Noguaranteethatthisrepresentationexistsforagivencurve/surface–z=f(x,y)cannotrepresenta(full)sphere.•Somecurvesandsurfacesmaynothaveanexplicitrepresentation.•Coordinate-system-dependenteffect.•Easytoobtainpointsonthem.计算机图形学讲义-16ImplicitRepresentations•f(x,y,z)=0in3Dorf(x,y)=0in2D.–Lesscoordinate-system-dependent:itdoesrepresentalllines/circles.–Allowtodeterminewhetherpointslieonthecurve/surface.–Difficulttofindpointsonthecurve/surface.•Curvesin3Darenoteasilyrepresentedinimplicitform–becauseittakestwoequationstorepresentacurvein3D–f(x,y,z)=0andg(x,y,z)=0•“Ingeneral,mostofthecurvesandsurfacesthatariseinrealapplicationshaveimplicitrepresentations.Theiruseislimitedbythedifficultinobtainingpointsonthem.”[EA,p.600]•Algebraicsurfaces:f(x,y,z)isapolynomial.–Ofparticularimportancearethequadricsurfaces.计算机图形学讲义-16ParametricForm•Sameformin2Dand3D.•Mostflexibleandrobustforcomputergraphicsthantheothers.••Stillcoordinate-system-dependent.•Coordinate-system-independentrepresentationsarepossible–UsingFrenetframeforcurves.•Difficulttodetermineifapointisonthecurve/surface.(,),(,),(,),xxuvyyuvzzuvxxuvyynuvzzuv计算机图形学讲义-16ParametricPolynomialCurves/Surfaces•Parametricrepresentationsarenotunique.•Parametricpolynomialformsareofmostuseincomputergraphics.minmaxminmax(,),,(,),.(,),xxuvuuuyyuvvvvzzuvminmax(),(),.(),xxuyyuuuuzzuSurfacePatchCurveSegment计算机图形学讲义-16DesignCriteria–Localcontrolofshape:•Asingleglobaldescriptionisgenerallyoutofthequestionandtoocomplex.•Wewouldlike/havetoworkinteractivelywiththeshape,carefullymoldingitmeetspecifications–Smoothnessandcontinuityatjointpoints•Acurvewithdiscontinuityisoflittleinteresttous.•Notonlywilleachsegmenthavetobesmooth,butalsowewantadegreeofsmoothnesswherethesegmentsmeetatjointpoint.•Smoothnessismeasuredwithderivativesalongthecurves/surfaces.•Abilitytoevaluatederivativesisneededtoevaluatesmoothnessandnormals.–Stability•Itisnecessarytobendcurves/surfacestothedesiredshapethroughlocalcontrolpoints.•Whenwemakeachange,thischangewillonlyaffecttheshapeinonlytheareawhereweareworking.•Weareusuallysatisfiedifthecurve/surfacepassesclosetothecontrolpoints,–EaseofRendering•Goodmathrepresentationsmaybeoflimitedvalueiftheycannotbeefficientlyrendered.计算机图形学讲义-16Splines•Splinesaretypesofcurves,originallydevelopedforship-buildinginthedaysbeforecomputermodeling.•Navalarchitectsneededawaytodrawasmoothcurvethroughasetofpoints.•Thesolutionwastoplacemetalweights(calledknots)atthecontrolpoints,andbendathinmetalorwoodenbeam(calledaspline)throughtheweights.•Thephysicsofthebendingsplinemeantthattheinfluenceofeachweightwasgreatestatthepointofcontact,anddecreasedsmoothlyfurtheralongthespline.•Togetmorecontroloveracertainregionofthespline,thedraftsmansimplyaddedmoreweights.•Thisschemehadobviousproblemswithdataexchange!•Peopleneededamathematicalwaytodescribetheshapeofthecurve.•CubicPolynomialsSplinesarethemathematicalequivalentofthedraftsman'swoodenbeam.•PolynomialswereextendedtoB-splines(forBasissplines),whicharesumsoflower-levelpolynomialsplines.•ThenB-splineswereextendedtocreateamathematicalrepresentationcalledNURBS.•ReadHistoryofSplinesEditedfrom计算机图形学讲义-16ParametricCubicPolynomialCurves•Wemustchoosethedegreeofpolynomials.•Ifwechoosehigherdegree–WewillhavemoreparametersthatwecansettofromthedesiredshapeCubicisenough.–Theevaluationofpointswillbecostly.–Thereismoredangerthatthecurvewillbecomerougheratsomepoints.•Ifwepicktoolowadegree,wemaynothaveenoughparameterstoworkandtomakethemtojoinsmoothly.•Ifwedesigneachcurvesegmentoverashortinterval,wecanachievemanyofourpurposeswithlow-degreecurves.•Cubicpolynomialsarechosen,atleastinitially.230123012233()uc,1u,c,.Tkxkkykpuccucucucccucccuccu•cistobedeterminedfromthecontrol-pointdata.•Typesofcubiccurvesdifferinhowtheyusethecontrol-pointdata.•ThedatamaybeInterpolating:thepolynomialmustpasssomepoints.•Higherorderinterpolatingatcertainparametervalues.•Smoothnessconditionsatjoinpoints.•Approximative:thecurvepassclosetosomedatapoints.计算机图形学讲义-16CubicInterpolatingPolynomial•Supposethatwehavefourcontrolpointsin3D.•Weseekthecoefficientscsuchthatthepolynomialp(u)=uTcpassesthroughthefourpoints.•Weassume–theintervalis[0,1],–thecurvepassesfourpointsatu=0,1/3,2/3,and1.计算机图形学讲义
本文标题:第十六讲 Curves and Surfaces (I)
链接地址:https://www.777doc.com/doc-3240844 .html