SlideShare a Scribd company logo
CS 354
Bézier Curves
Mark Kilgard
University of Texas
April 5, 2012
CS 354                                       2



         Today’s material
        In-class quiz
            On procedural methods lecture
        Lecture topic
          Project 2
          Bézier curves
CS 354                                                    3



         My Office Hours
        Tuesday, before class
            Painter (PAI) 5.35
            8:45 a.m. to 9:15
        Thursday, after class
            ACE 6.302, just for today, in ENS basement
            11:00 a.m. to 12


        Randy’s office hours
            Monday & Wednesday
            11 a.m. to 12:00
            Painter (PAI) 5.33
CS 354                                         4



         Last time, this time
        Last lecture, we discussed
          Project 2 on Programmable Shaders
          Procedural Methods
              L-Systems
              Particle systems

              Perlin Noise

        This lecture
          Project 2 discussion
          Bézier curves
        Project 2 due is due Friday
CS 354                                                                      5

                               On a sheet of paper
         Daily Quiz            • Write your EID, name, and date
                               • Write #1, #2, #3, followed by its answer
        Multiple choice: A              True or False: Perlin’s
         stochastic L-system              noise function sums up
                                          multiple versions of
         a) repeats the same rule         turbulence.
         forever
                                         List three forces that
         b) varies the rules              a particle system
         randomly
                                          could model
         c) uses biology to make
         mountains
CS 354                                               6



         Your Mission So Far
        You should now have these first two
         shaders tasks implemented

                               Task 1: apply decal




          Task 0: roll torus
CS 354                                                  7

         Procedurally Generating a
         Torus from a 2D Grid




         2D grid over (s,t)∈[0,1]
                                    Tessellated torus
CS 354                                                                               8

         GLSL Standard Library Routines
         You’ll Need for Project 2
        texture2D—accesses a 2D texture through a sampler2D and a 2-component
         texture coordinate set (s,t)
        textureCube—access a cube map with a samplerCube and a 3-component
         texture coordinate set (s,t,r)
        normalize—normalizes a vector
        cross—computes a cross product of 2 vectors
        dot—computes a dot (inner) product of 2 vectors
        max—compute the maximum of two values
        reflect—compute a reflection vector given an incident vector and a normal
         vector
        vec3—constructor for 3-component vector from scalars
        mat3—constructor for 3x3 matrix from column vectors
        *—matrix-by-vector or vector-by-matrix multiplication
        sin—sine trigonometric function
        cos—cosine trigonometric function
        pow—raise a number to a power, exponentiation (hint: specular)
CS 354                                                                       9



          Normal Maps Visualized

      texas_-
    longhorn2
                                          normal map
                                          construction




         bumps_in
                                          normal map
                                          construction



         Hint: dump your normal map computeNormal calls in NormalMap::load

         stbi_write_tga(buffer, width, height, 3, normal_image);
CS 354                                                                     10

         Other Normal Maps



                                                 mosaic     geforce_etch
         stripes

                           texas_longhorn




                                     bumps_out

                   brick                                  geforce_cell
CS 354                                                                     11



         Coordinate Spaces for Project 2
        Parametric space
            2D space [0..1]x[0..1] for 2D patch
        Object space
          Transform the patch’s parametric space into a 3D space
           containing a torus
          Has modeling transformation from object- to world-space
        World space
          Environment map is oriented in this space
          gluLookAt’s coordinates are in this space
        Surface space
          (0,0,1) is always surface normal direction
          Mapping from object space to surface space varies along torus
          Perturbed normal from normal map overrides (0,0,1) geometric
           normal
        Eye space
            gluLookAt transforms world space to eye space
CS 354                                                             12



         Making Curves




         Spline weights used to create curve without computers 
CS 354                                             13



         Moving Between Two Points
        Given 2 or more points, how can we move
         between them?
            Easy answer: in a straight line




        Linear interpolation
            p(t) = p0 + t (p1-p0)
        Jagged! Can we make something smoother?
CS 354                                            14



         Types of curves
            Variety of curve formulations
                Interpolating
                Hermite
                Bézier
                B-spline
            Explore their characteristics



                                             14
CS 354                                               15



         Matrix-Vector Form of Cubic
                                 3
                      p(u ) = ∑ c k u k
                                k =0

                       c 0             1
                                       u 
           define   c=  c1         u =  2
                       c 2             u 
                                        3
                        c3             u 


            then    p(u ) = u c = c u
                                 T          T


                                                15
CS 354                                                              16



         Interpolating Curve

                              p1                     p3


                   p0                   p2

           Given four data (control) points p0 , p1 ,p2 , p3
           determine cubic p(u) which passes through them

           Must find c0 ,c1 ,c2 , c3


                                                               16
CS 354                                                                 17



         Interpolation Equations

         apply the interpolating conditions at u=0, 1/3, 2/3, 1
              p0=p(0)=c0
              p1=p(1/3)=c0+(1/3)c1+(1/3)2c2+(1/3)3c2
              p2=p(2/3)=c0+(2/3)c1+(2/3)2c2+(2/3)3c2
              p3=p(1)=c0+c1+c2+c2
           or in matrix form with p = [p0 p1 p2 p3]T
                              1     0      0        0 
                                  1     1
                                               2
                                                    1 
                                                       3

                              1                 
                                    3    3      3 
             p=Ac           A=
                                   2    2
                                               2
                                                    2 
                                                       3

                              1                 
                                   3    3      3 
                              1
                                    1      1        1  
                                                                  17
CS 354                                                            18



         Interpolation Matrix

         Solving for c we find the interpolation matrix

                          1      0      0    0 
                          − 5.5  9   − 4.5   1 
               M I = A =  9 − 22.5 18 − 4.5
                      −1

                                                
                                                
                          − 4.5 13.5 − 13.5 4.5 


                         c=MIp
            Note that MI does not depend on input data and
            can be used for each segment in x, y, and z

                                                             18
CS 354                                                                19

         Interpolating Multiple
         Segments




          use p = [p0 p1 p2 p3]   T     use p = [p3 p4 p5 p6]T


           Get continuity at join points but not
           continuity of derivatives


                                                                 19
CS 354                                                     20



          Blending Functions

     Rewriting the equation for p(u)
                    p(u)=uTc=uTMIp = b(u)Tp
         where b(u) = [b0(u) b1(u) b2(u) b3(u)]T is
         an array of blending polynomials such that
         p(u) = b0(u)p0+ b1(u)p1+ b2(u)p2+ b3(u)p3
              b0(u) = -4.5(u-1/3)(u-2/3)(u-1)
              b1(u) = 13.5u (u-2/3)(u-1)
              b2(u) = -13.5u (u-1/3)(u-1)
              b3(u) = 4.5u (u-1/3)(u-2/3)
                                                      20
CS 354                                                            21



         Blending Functions
            These functions are not smooth
                Hence the interpolation polynomial is not
                 smooth




                                                             21
CS 354                                                                  22



          Interpolating Patch
                              3      3
                   p(u , v) = ∑     ∑ cij
                                           i
                                          u vj
                             i =o   j =0


         Need 16 conditions to determine the 16 coefficients cij
         Choose at u,v = 0, 1/3, 2/3, 1




                                                                   22
CS 354                                                           23



         Matrix Form

              Define v = [1 v v2 v3]T

                     C = [cij]   P = [pij]
                   p(u,v) = uTCv

         If we observe that for constant u (v), we obtain
         interpolating curve in v (u), we can show
                            C=MIPMI
                     p(u,v) = uTMIPMITv


                                                            23
CS 354                                                            24



         Blending Patches

                           3      3
               p(u , v) = ∑      ∑ b (u ) b
                                        i     j   (v ) pij
                          i =o   j =0


          Each bi(u)bj(v) is a blending patch


          Shows that we can build and analyze surfaces
          from our knowledge of curves




                                                             24
CS 354                                                       25

         Other Types of Curves and
         Surfaces
        How can we get around the limitations of
         the interpolating form
            Lack of smoothness
            Discontinuous derivatives at join points
        We have four conditions (for cubics) that
         we can apply to each segment
            Use them other than for interpolation
            Need only come close to the data

                                                        25
CS 354                                                       26



         Hermite Form

                   p’(0)           p’(1)




            p(0)                                 p(1)

            Use two interpolating conditions and
            two derivative conditions per segment
            Ensures continuity and first derivative
            continuity between segments
                                                        26
CS 354                                                         27



         Equations

         Interpolating conditions are the same at ends

                        p(0) = p0 = c0
                        p(1) = p3 = c0+c1+c2+c3

          Differentiating we find p’(u) = c1+2uc2+3u2c3

          Evaluating at end points
                      p’(0) = p’0 = c1
                      p’(1) = p’3 = c1+2c2+3c3


                                                          27
CS 354                                                                28



         Matrix Form
                          p 0  1   0   0   0
                          p  1     1   1   1
                     q =  3 =               c
                         p'0  0    1   0   0
                                            
                          p'3 0    1   2   3
         Solving, we find c=MHq where MH is the Hermite matrix

                             1   0  0  0
                             0   0  1  0
                    M       =             
                        H
                             − 3 3 − 2 − 1
                                          
                              2 −2 1   1
                                                                 28
CS 354                                                                     29



         Blending Polynomials
                           p(u) = b(u)Tq
                             2 u 3 − 3 u 2 + 1
                                              
                               − 2 u3 + 3 u 2 
                     b(u ) =  3
                              u − 2 u2 + u 
                                              
                              u −u
                                    3     2
                                               
         Although these functions are smooth, the Hermite form
         is not used directly in Computer Graphics and CAD
         because we usually have control points but not derivatives

         However, the Hermite form is the basis of the Bézier form
                                                                      29
CS 354                                                 30

         Parametric and Geometric
         Continuity
     We   can require the derivatives of x, y, and
      z to each be continuous at join points
      (parametric continuity)
     Alternately, we can only require that the
      tangents of the resulting curve be
      continuous (geometry continuity)
     The latter gives more flexibility as we have
      need satisfy only two conditions rather than
      three at each join point
                                                  30
CS 354                                                  31



         Example
        Here the p and q have the same
         tangents at the ends of the segment but
         different derivatives
      Generate different

        Hermite curves
      This techniques is used

     in drawing applications


                                                   31
CS 354                                                   32

         Higher Dimensional
         Approximations
        The techniques for both interpolating and
         Hermite curves can be used with higher
         dimensional parametric polynomials
        For interpolating form, the resulting matrix
         becomes increasingly more ill-conditioned
         and the resulting curves less smooth and
         more prone to numerical errors
        In both cases, there is more math
         operations in rendering the resulting
         polynomial curves and surfaces
                                                    32
CS 354                                                         33



         Pierre Bézier
      French engineer at Renault
      Popularized Bézier curves
       and surfaces
            For computer-aided design
        Winner: ACM Steven Anson Coons
         Award for Outstanding Creative
         Contributions to Computer Graphics
            2nd winner, after 1st winner Ivan Sutherland of
             SketchPad fame
CS 354                                                 34



         Bézier’s Idea
        In graphics and CAD, we do not usually
         have derivative data
        Bézier suggested using the 4 data points
         as with the cubic interpolating curve to
         approximate the derivatives in the Hermite
         form




                                                  34
CS 354                                                             35



         Approximating Derivatives

                            p1       p2




                  p1 − p0                          p3 − p 2
         p' (0) ≈                         p' (1) ≈
                   1/ 3                             1/ 3


     slope p’(0)                                   slope p’(1)

                   p0                         p3
                                 u

                                                              35
CS 354                                                    36



         Equations
         Interpolating conditions are the same
                          p(0) = p0 = c0
                          p(1) = p3 = c0+c1+c2+c3
         Approximating derivative conditions
                    p’(0) = 3(p1- p0) = c0
                    p’(1) = 3(p3- p2) = c1+2c2+3c3

         Solve four linear equations for c=MBp



                                                     36
CS 354                                          37



         Bézier Matrix

                     1   0  0        0
                     − 3 3  0         
                                      0
                     
                MB =  3 − 6 3        0
                                      
                      −1 3 − 3       1


                  p(u) = uTMBp = b(u)Tp

              blending functions

                                           37
CS 354                                                              38



         Blending Functions

                  (1− u)3 
                           2
          b(u) = 3u (1− u) 
                 3 u2 (1− u)
                            
                  u         
                         3




             Note that all zeros are at 0 and 1 which forces
             the functions to be smooth over (0,1)


                                                               38
CS 354                                                         39



         Bernstein Polynomials
        The blending functions are a special case
         of the Bernstein polynomials
                              d!                 d −k
               bkd (u ) =             u (1 − u )
                                       k

                          k!(d − k )!
        These polynomials give the blending
         polynomials for any degree Bézier form
             All zeros at 0 and 1
             For any degree they all sum to 1
             They are all between 0 and 1 inside (0,1)
                                                          39
CS 354                                                          40



         Convex Hull Property
        The properties of the Bernstein polynomials
         ensure that all Bézier curves lie in the convex
         hull of their control points
        Hence, even though we do not interpolate all
         the data, we cannot be too far away
                     p1            p2
                                            convex hull
    Bézier curve

               p0                             p3

                                                           40
CS 354                                                                   41



          Bézier Patches

         Using same data array P=[pij] as with interpolating form
                          3    3
             p (u , v) = ∑∑ bi (u ) b j (v) pij = uT M B P MT v
                                                            B
                         i =0 j =0


         Patch lies in
         convex hull




                                                                    41
CS 354                                                             42



         Analysis
            Although the Bézier form is much better than
             the interpolating form, we have the derivatives
             are not continuous at join points
            Can we do better?
               Go to higher order Bézier
                   More work

                   Derivative continuity still only

                     approximate
                 Apply different conditions
                     Tricky without letting order increase   42
CS 354                                                           43



         Evaluating Polynomials
            Simplest method to render a polynomial curve
             is to evaluate the polynomial at many points
             and form an approximating polyline
            For surfaces we can form an approximating
             mesh of triangles or quadrilaterals
            Use Horner’s method to evaluate polynomials
                    p(u)=c0+u(c1+u(c2+uc3))
                  3 multiplications/evaluation for cubic



                                                            43
CS 354                                                               44



         Finite Differences
         For equally spaced {uk} we define finite differences

                        ∆p k=( k
                          ()
                          0
                         ( ) p )
                          u   u
                ∆(k=(k1 pk
                 p ) p +− u
                  ()
                  1
                  u   u ) ( )
            (+
          ∆ pk ∆ (k1 ∆ (k
            m
             u = p +− p )
             1
            ())
                  u )  u
                                ()
                                m                   ()
                                                    m



            For a polynomial of degree n,
            the nth finite difference is constant

                                                                44
CS 354                                       45

         Building a Finite Difference
         Table
     p(u)=1+3u+2u2+u3




                                        45
CS 354                                                         46



         deCasteljau Recursion
        We can use the convex hull property of
         Bézier curves to obtain an efficient
         recursive method that does not require
         any function evaluations
            Uses only the values at the control points
        Based on the idea that “any polynomial
         and any part of a polynomial is a Bézier
         polynomial for properly chosen control
         data”
                                                          46
CS 354                                                               47



         Splitting a Cubic Bézier

         p0, p1 , p2 , p3 determine a cubic Bézier polynomial
         and its convex hull




               Consider left half l(u) and right half r(u)
                                                                47
CS 354                                                                           48



         l(u) and r(u)
         Since l(u) and r(u) are Bézier curves, we should be able to
         find two sets of control points {l0, l1, l2, l3} and {r0, r1, r2, r3}
         that determine them




                                                                            48
CS 354                                                                        49



         Convex Hulls
         {l0, l1, l2, l3} and {r0, r1, r2, r3}each have a convex hull that
         that is closer to p(u) than the convex hull of {p0, p1, p2, p3}
         This is known as the variation diminishing property.
         The polyline from l0 to l3 (= r0) to r3 is an approximation
         to p(u). Repeating recursively we get better approximations.




                                                                         49
CS 354                                                                      50



         Equations

              Start with Bézier equations p(u)=uTMBp
              l(u) must interpolate p(0) and p(1/2)
               l(0) = l0 = p0
               l(1) = l3 = p(1/2) = 1/8( p0 +3 p1 +3 p2 + p3 )
         Matching slopes, taking into account that l(u) and r(u)
         only go over half the distance as p(u)
              l’(0) = 3(l1 - l0) = p’(0) = 3/2(p1 - p0 )
              l’(1) = 3(l3 – l2) = p’(1/2) = 3/8(- p0 - p1+ p2 + p3)

          Symmetric equations hold for r(u)
                                                                       50
CS 354                                             51



         Efficient Form

          l0 = p0
          r3 = p3
          l1 = ½(p0 + p1)
          r1 = ½(p2 + p3)
          l2 = ½(l1 + ½( p1 + p2))
          r1 = ½(r2 + ½( p1 + p2))
          l3 = r0 = ½(l2 + r1)

             Requires only shifts and adds!

                                              51
CS 354                                                          52

         Every Polynomial is a
         Bézier Curve
     We  can render a given polynomial using the
      recursive method if we find control points for its
      representation as a Bézier curve
     Suppose that p(u) is given as an interpolating
      curve with control points q
                        p(u)=uTMIq
     There   exist Bézier control points p such that
                        p(u)=uTMBp
     Equating   and solving, we find p=MB-1MI

                                                           52
CS 354                                                              53



         Conversion Matrix
                                            1    0     0     0 
                                            5           3    1 
                                           − 6   3    −
                                                         2    3 
                                   MB MI =  1
                                    −1
         Interpolating to Bézier                   3           5
                                                 −     3    − 
                                            3     2           6
                                            0
                                                 0     0     1 
                                                                
CS 354                                                                 54



         Example

         These two curves were all generated from the same
         original data using Bézier recursion by converting all
         control point data to Bézier control points




                   Bézier              Interpolating

                                                                  54
CS 354                                                                  55



         Surfaces
     Can   apply the recursive method to surfaces if we
      recall that for a Bézier patch curves of constant u
      (or v) are Bézier curves in u (or v)
     First subdivide in u
         Process creates new points
         Some of the original points are discarded
                                               original and discarded




                    original and kept             new
                                                                  55
CS 354                                 56



         Second Subdivision




         16 final points for
         1 of 4 patches created
                                  56
CS 354                                                    57



         Normals
        For rendering we need the normals if we
         want to shade
            Can compute from parametric equations
                       ∂p(u , v) ∂p(u , v)
                    n=          ×
                         ∂u        ∂v

            Can use vertices of corner points to
             determine
            OpenGL can compute automatically
                                                     57
CS 354                                                         58



         Utah Teapot
         Most  famous data set in computer graphics
         Widely available as a list of 306 3D vertices and
          the indices that define 32 Bézier patches




                                                          58
CS 354                                                        59



         Quadrics
     Any quadric can be written as the quadratic form
        pTAp+bTp+c=0 where p=[x, y, z]T
        with A, b and c giving the coefficients
     Render by ray casting
       Intersect with parametric ray p(α)=p0+αd that
        passes through a pixel
       Yields a scalar quadratic equation
          No solution: ray misses quadric

          One solution: ray tangent to quadric

          Two solutions: entry and exit points
                                                         59
CS 354                                                            60



         Next Class
        Next lecture
            Vector graphics and path rendering
            Resolution independent 2D graphics
        Project 3 to be assigned
            Animate a virtual person using motion capture data
        Reading
          Procedural methods: Chapter 9, 465-499
          Curves: Chapter 10, 503-522


        Remember Project 2
            Shading and lighting with GLSL
            Due Friday, April 6th
CS 354                                         61



         Thanks
     • E. Angel and D. Shreiner: Interactive
       Computer Graphics 6E © Addison-Wesley
       2012

More Related Content

What's hot

Output primitives computer graphics c version
Output primitives   computer graphics c versionOutput primitives   computer graphics c version
Output primitives computer graphics c version
Marwa Al-Rikaby
 
Representation image
Representation imageRepresentation image
Representation image
Zena Abo-Altaheen
 
B. SC CSIT Computer Graphics Unit 3 By Tekendra Nath Yogi
B. SC CSIT Computer Graphics Unit 3 By Tekendra Nath YogiB. SC CSIT Computer Graphics Unit 3 By Tekendra Nath Yogi
B. SC CSIT Computer Graphics Unit 3 By Tekendra Nath Yogi
Tekendra Nath Yogi
 
Image feature extraction
Image feature extractionImage feature extraction
Image feature extractionRushin Shah
 
Two Dimensional Shape and Texture Quantification - Medical Image Processing
Two Dimensional Shape and Texture Quantification - Medical Image ProcessingTwo Dimensional Shape and Texture Quantification - Medical Image Processing
Two Dimensional Shape and Texture Quantification - Medical Image Processing
Chamod Mune
 
Performance analysis of chain code descriptor for hand shape classification
Performance analysis of chain code descriptor for hand shape classificationPerformance analysis of chain code descriptor for hand shape classification
Performance analysis of chain code descriptor for hand shape classification
ijcga
 
Visual pattern recognition
Visual pattern recognitionVisual pattern recognition
Visual pattern recognitionRushin Shah
 
Line drawing algo.
Line drawing algo.Line drawing algo.
Line drawing algo.Mohd Arif
 
Computer graphics 2
Computer graphics 2Computer graphics 2
Computer graphics 2
Prabin Gautam
 
Quadric surfaces
Quadric surfacesQuadric surfaces
Quadric surfaces
Ankur Kumar
 
bresenham circles and polygons in computer graphics(Computer graphics tutorials)
bresenham circles and polygons in computer graphics(Computer graphics tutorials)bresenham circles and polygons in computer graphics(Computer graphics tutorials)
bresenham circles and polygons in computer graphics(Computer graphics tutorials)
Daroko blog(www.professionalbloggertricks.com)
 
Digital Differential Analyzer Line Drawing Algorithm
Digital Differential Analyzer Line Drawing AlgorithmDigital Differential Analyzer Line Drawing Algorithm
Digital Differential Analyzer Line Drawing Algorithm
Kasun Ranga Wijeweera
 
Geometric model & curve
Geometric model & curveGeometric model & curve
Geometric model & curve
sai surendra veerla
 
3D Curve Project
3D Curve Project3D Curve Project
3D Curve Project
graphitech
 
Output primitives in Computer Graphics
Output primitives in Computer GraphicsOutput primitives in Computer Graphics
Output primitives in Computer Graphics
Kamal Acharya
 
CS 354 Typography
CS 354 TypographyCS 354 Typography
CS 354 Typography
Mark Kilgard
 
Chapter 3 Output Primitives
Chapter 3 Output PrimitivesChapter 3 Output Primitives
Chapter 3 Output Primitives
PrathimaBaliga
 
Clipping 22
Clipping 22Clipping 22
Clipping 22
Lokesh Reddy
 
CAD Topology and Geometry Basics
CAD Topology and Geometry BasicsCAD Topology and Geometry Basics
CAD Topology and Geometry BasicsAndrey Dankevich
 
COMPUTER GRAPHICS
COMPUTER GRAPHICSCOMPUTER GRAPHICS
COMPUTER GRAPHICS
Jagan Raja
 

What's hot (20)

Output primitives computer graphics c version
Output primitives   computer graphics c versionOutput primitives   computer graphics c version
Output primitives computer graphics c version
 
Representation image
Representation imageRepresentation image
Representation image
 
B. SC CSIT Computer Graphics Unit 3 By Tekendra Nath Yogi
B. SC CSIT Computer Graphics Unit 3 By Tekendra Nath YogiB. SC CSIT Computer Graphics Unit 3 By Tekendra Nath Yogi
B. SC CSIT Computer Graphics Unit 3 By Tekendra Nath Yogi
 
Image feature extraction
Image feature extractionImage feature extraction
Image feature extraction
 
Two Dimensional Shape and Texture Quantification - Medical Image Processing
Two Dimensional Shape and Texture Quantification - Medical Image ProcessingTwo Dimensional Shape and Texture Quantification - Medical Image Processing
Two Dimensional Shape and Texture Quantification - Medical Image Processing
 
Performance analysis of chain code descriptor for hand shape classification
Performance analysis of chain code descriptor for hand shape classificationPerformance analysis of chain code descriptor for hand shape classification
Performance analysis of chain code descriptor for hand shape classification
 
Visual pattern recognition
Visual pattern recognitionVisual pattern recognition
Visual pattern recognition
 
Line drawing algo.
Line drawing algo.Line drawing algo.
Line drawing algo.
 
Computer graphics 2
Computer graphics 2Computer graphics 2
Computer graphics 2
 
Quadric surfaces
Quadric surfacesQuadric surfaces
Quadric surfaces
 
bresenham circles and polygons in computer graphics(Computer graphics tutorials)
bresenham circles and polygons in computer graphics(Computer graphics tutorials)bresenham circles and polygons in computer graphics(Computer graphics tutorials)
bresenham circles and polygons in computer graphics(Computer graphics tutorials)
 
Digital Differential Analyzer Line Drawing Algorithm
Digital Differential Analyzer Line Drawing AlgorithmDigital Differential Analyzer Line Drawing Algorithm
Digital Differential Analyzer Line Drawing Algorithm
 
Geometric model & curve
Geometric model & curveGeometric model & curve
Geometric model & curve
 
3D Curve Project
3D Curve Project3D Curve Project
3D Curve Project
 
Output primitives in Computer Graphics
Output primitives in Computer GraphicsOutput primitives in Computer Graphics
Output primitives in Computer Graphics
 
CS 354 Typography
CS 354 TypographyCS 354 Typography
CS 354 Typography
 
Chapter 3 Output Primitives
Chapter 3 Output PrimitivesChapter 3 Output Primitives
Chapter 3 Output Primitives
 
Clipping 22
Clipping 22Clipping 22
Clipping 22
 
CAD Topology and Geometry Basics
CAD Topology and Geometry BasicsCAD Topology and Geometry Basics
CAD Topology and Geometry Basics
 
COMPUTER GRAPHICS
COMPUTER GRAPHICSCOMPUTER GRAPHICS
COMPUTER GRAPHICS
 

Similar to CS 354 Bezier Curves

CS 354 Procedural Methods
CS 354 Procedural MethodsCS 354 Procedural Methods
CS 354 Procedural Methods
Mark Kilgard
 
Spike sorting: What is it? Why do we need it? Where does it come from? How is...
Spike sorting: What is it? Why do we need it? Where does it come from? How is...Spike sorting: What is it? Why do we need it? Where does it come from? How is...
Spike sorting: What is it? Why do we need it? Where does it come from? How is...
NeuroMat
 
Ee693 sept2014midsem
Ee693 sept2014midsemEe693 sept2014midsem
Ee693 sept2014midsem
Gopi Saiteja
 
kactl.pdf
kactl.pdfkactl.pdf
kactl.pdf
Rayhan331
 
Answers withexplanations
Answers withexplanationsAnswers withexplanations
Answers withexplanations
Gopi Saiteja
 
Integral calculus formula sheet 0
Integral calculus formula sheet 0Integral calculus formula sheet 0
Integral calculus formula sheet 0
DELHI STATE, TECHNICAL EDUCATION
 
Integral calculus formula sheet
Integral calculus formula sheetIntegral calculus formula sheet
Integral calculus formula sheet
AjEcuacion
 
Integral calculus formula sheet
Integral calculus formula sheetIntegral calculus formula sheet
Integral calculus formula sheet
HimadriBiswas10
 
Paper computer
Paper computerPaper computer
Paper computerbikram ...
 
Paper computer
Paper computerPaper computer
Paper computerbikram ...
 
"Mesh of Periodic Minimal Surfaces in CGAL."
"Mesh of Periodic Minimal Surfaces in CGAL.""Mesh of Periodic Minimal Surfaces in CGAL."
"Mesh of Periodic Minimal Surfaces in CGAL."
Vissarion Fisikopoulos
 
CS 354 Final Exam Review
CS 354 Final Exam ReviewCS 354 Final Exam Review
CS 354 Final Exam Review
Mark Kilgard
 
SU(3) fermions in a three-band graphene-like model
SU(3) fermions in a three-band graphene-like modelSU(3) fermions in a three-band graphene-like model
SU(3) fermions in a three-band graphene-like model
AnkurDas60
 
4th Semester (Dec-2015; Jan-2016) Computer Science and Information Science En...
4th Semester (Dec-2015; Jan-2016) Computer Science and Information Science En...4th Semester (Dec-2015; Jan-2016) Computer Science and Information Science En...
4th Semester (Dec-2015; Jan-2016) Computer Science and Information Science En...
BGS Institute of Technology, Adichunchanagiri University (ACU)
 
Trident International Graphics Workshop 2014 4/5
Trident International Graphics Workshop 2014 4/5Trident International Graphics Workshop 2014 4/5
Trident International Graphics Workshop 2014 4/5
Takao Wada
 
Computer Network Assignment Help
Computer Network Assignment HelpComputer Network Assignment Help
Computer Network Assignment Help
Computer Network Assignment Help
 
Parallel Evaluation of Multi-Semi-Joins
Parallel Evaluation of Multi-Semi-JoinsParallel Evaluation of Multi-Semi-Joins
Parallel Evaluation of Multi-Semi-Joins
Jonny Daenen
 
Do's and Don'ts of using t-SNE.pdf
Do's and Don'ts of using t-SNE.pdfDo's and Don'ts of using t-SNE.pdf
Do's and Don'ts of using t-SNE.pdf
FrankClat
 
Passive network-redesign-ntua
Passive network-redesign-ntuaPassive network-redesign-ntua
Passive network-redesign-ntua
IEEE NTUA SB
 

Similar to CS 354 Bezier Curves (20)

CS 354 Procedural Methods
CS 354 Procedural MethodsCS 354 Procedural Methods
CS 354 Procedural Methods
 
Spike sorting: What is it? Why do we need it? Where does it come from? How is...
Spike sorting: What is it? Why do we need it? Where does it come from? How is...Spike sorting: What is it? Why do we need it? Where does it come from? How is...
Spike sorting: What is it? Why do we need it? Where does it come from? How is...
 
Ee693 sept2014midsem
Ee693 sept2014midsemEe693 sept2014midsem
Ee693 sept2014midsem
 
kactl.pdf
kactl.pdfkactl.pdf
kactl.pdf
 
Answers withexplanations
Answers withexplanationsAnswers withexplanations
Answers withexplanations
 
testpang
testpangtestpang
testpang
 
Integral calculus formula sheet 0
Integral calculus formula sheet 0Integral calculus formula sheet 0
Integral calculus formula sheet 0
 
Integral calculus formula sheet
Integral calculus formula sheetIntegral calculus formula sheet
Integral calculus formula sheet
 
Integral calculus formula sheet
Integral calculus formula sheetIntegral calculus formula sheet
Integral calculus formula sheet
 
Paper computer
Paper computerPaper computer
Paper computer
 
Paper computer
Paper computerPaper computer
Paper computer
 
"Mesh of Periodic Minimal Surfaces in CGAL."
"Mesh of Periodic Minimal Surfaces in CGAL.""Mesh of Periodic Minimal Surfaces in CGAL."
"Mesh of Periodic Minimal Surfaces in CGAL."
 
CS 354 Final Exam Review
CS 354 Final Exam ReviewCS 354 Final Exam Review
CS 354 Final Exam Review
 
SU(3) fermions in a three-band graphene-like model
SU(3) fermions in a three-band graphene-like modelSU(3) fermions in a three-band graphene-like model
SU(3) fermions in a three-band graphene-like model
 
4th Semester (Dec-2015; Jan-2016) Computer Science and Information Science En...
4th Semester (Dec-2015; Jan-2016) Computer Science and Information Science En...4th Semester (Dec-2015; Jan-2016) Computer Science and Information Science En...
4th Semester (Dec-2015; Jan-2016) Computer Science and Information Science En...
 
Trident International Graphics Workshop 2014 4/5
Trident International Graphics Workshop 2014 4/5Trident International Graphics Workshop 2014 4/5
Trident International Graphics Workshop 2014 4/5
 
Computer Network Assignment Help
Computer Network Assignment HelpComputer Network Assignment Help
Computer Network Assignment Help
 
Parallel Evaluation of Multi-Semi-Joins
Parallel Evaluation of Multi-Semi-JoinsParallel Evaluation of Multi-Semi-Joins
Parallel Evaluation of Multi-Semi-Joins
 
Do's and Don'ts of using t-SNE.pdf
Do's and Don'ts of using t-SNE.pdfDo's and Don'ts of using t-SNE.pdf
Do's and Don'ts of using t-SNE.pdf
 
Passive network-redesign-ntua
Passive network-redesign-ntuaPassive network-redesign-ntua
Passive network-redesign-ntua
 

More from Mark Kilgard

D11: a high-performance, protocol-optional, transport-optional, window system...
D11: a high-performance, protocol-optional, transport-optional, window system...D11: a high-performance, protocol-optional, transport-optional, window system...
D11: a high-performance, protocol-optional, transport-optional, window system...
Mark Kilgard
 
Computers, Graphics, Engineering, Math, and Video Games for High School Students
Computers, Graphics, Engineering, Math, and Video Games for High School StudentsComputers, Graphics, Engineering, Math, and Video Games for High School Students
Computers, Graphics, Engineering, Math, and Video Games for High School Students
Mark Kilgard
 
NVIDIA OpenGL and Vulkan Support for 2017
NVIDIA OpenGL and Vulkan Support for 2017NVIDIA OpenGL and Vulkan Support for 2017
NVIDIA OpenGL and Vulkan Support for 2017
Mark Kilgard
 
NVIDIA OpenGL 4.6 in 2017
NVIDIA OpenGL 4.6 in 2017NVIDIA OpenGL 4.6 in 2017
NVIDIA OpenGL 4.6 in 2017
Mark Kilgard
 
NVIDIA OpenGL in 2016
NVIDIA OpenGL in 2016NVIDIA OpenGL in 2016
NVIDIA OpenGL in 2016
Mark Kilgard
 
Virtual Reality Features of NVIDIA GPUs
Virtual Reality Features of NVIDIA GPUsVirtual Reality Features of NVIDIA GPUs
Virtual Reality Features of NVIDIA GPUs
Mark Kilgard
 
Migrating from OpenGL to Vulkan
Migrating from OpenGL to VulkanMigrating from OpenGL to Vulkan
Migrating from OpenGL to Vulkan
Mark Kilgard
 
EXT_window_rectangles
EXT_window_rectanglesEXT_window_rectangles
EXT_window_rectangles
Mark Kilgard
 
OpenGL for 2015
OpenGL for 2015OpenGL for 2015
OpenGL for 2015
Mark Kilgard
 
Slides: Accelerating Vector Graphics Rendering using the Graphics Hardware Pi...
Slides: Accelerating Vector Graphics Rendering using the Graphics Hardware Pi...Slides: Accelerating Vector Graphics Rendering using the Graphics Hardware Pi...
Slides: Accelerating Vector Graphics Rendering using the Graphics Hardware Pi...
Mark Kilgard
 
Accelerating Vector Graphics Rendering using the Graphics Hardware Pipeline
Accelerating Vector Graphics Rendering using the Graphics Hardware PipelineAccelerating Vector Graphics Rendering using the Graphics Hardware Pipeline
Accelerating Vector Graphics Rendering using the Graphics Hardware Pipeline
Mark Kilgard
 
NV_path rendering Functional Improvements
NV_path rendering Functional ImprovementsNV_path rendering Functional Improvements
NV_path rendering Functional Improvements
Mark Kilgard
 
OpenGL 4.5 Update for NVIDIA GPUs
OpenGL 4.5 Update for NVIDIA GPUsOpenGL 4.5 Update for NVIDIA GPUs
OpenGL 4.5 Update for NVIDIA GPUs
Mark Kilgard
 
SIGGRAPH Asia 2012: GPU-accelerated Path Rendering
SIGGRAPH Asia 2012: GPU-accelerated Path RenderingSIGGRAPH Asia 2012: GPU-accelerated Path Rendering
SIGGRAPH Asia 2012: GPU-accelerated Path Rendering
Mark Kilgard
 
SIGGRAPH Asia 2012 Exhibitor Talk: OpenGL 4.3 and Beyond
SIGGRAPH Asia 2012 Exhibitor Talk: OpenGL 4.3 and BeyondSIGGRAPH Asia 2012 Exhibitor Talk: OpenGL 4.3 and Beyond
SIGGRAPH Asia 2012 Exhibitor Talk: OpenGL 4.3 and Beyond
Mark Kilgard
 
Programming with NV_path_rendering: An Annex to the SIGGRAPH Asia 2012 paper...
Programming with NV_path_rendering:  An Annex to the SIGGRAPH Asia 2012 paper...Programming with NV_path_rendering:  An Annex to the SIGGRAPH Asia 2012 paper...
Programming with NV_path_rendering: An Annex to the SIGGRAPH Asia 2012 paper...
Mark Kilgard
 
GPU accelerated path rendering fastforward
GPU accelerated path rendering fastforwardGPU accelerated path rendering fastforward
GPU accelerated path rendering fastforward
Mark Kilgard
 
GPU-accelerated Path Rendering
GPU-accelerated Path RenderingGPU-accelerated Path Rendering
GPU-accelerated Path Rendering
Mark Kilgard
 
SIGGRAPH 2012: GPU-Accelerated 2D and Web Rendering
SIGGRAPH 2012: GPU-Accelerated 2D and Web RenderingSIGGRAPH 2012: GPU-Accelerated 2D and Web Rendering
SIGGRAPH 2012: GPU-Accelerated 2D and Web Rendering
Mark Kilgard
 
SIGGRAPH 2012: NVIDIA OpenGL for 2012
SIGGRAPH 2012: NVIDIA OpenGL for 2012SIGGRAPH 2012: NVIDIA OpenGL for 2012
SIGGRAPH 2012: NVIDIA OpenGL for 2012
Mark Kilgard
 

More from Mark Kilgard (20)

D11: a high-performance, protocol-optional, transport-optional, window system...
D11: a high-performance, protocol-optional, transport-optional, window system...D11: a high-performance, protocol-optional, transport-optional, window system...
D11: a high-performance, protocol-optional, transport-optional, window system...
 
Computers, Graphics, Engineering, Math, and Video Games for High School Students
Computers, Graphics, Engineering, Math, and Video Games for High School StudentsComputers, Graphics, Engineering, Math, and Video Games for High School Students
Computers, Graphics, Engineering, Math, and Video Games for High School Students
 
NVIDIA OpenGL and Vulkan Support for 2017
NVIDIA OpenGL and Vulkan Support for 2017NVIDIA OpenGL and Vulkan Support for 2017
NVIDIA OpenGL and Vulkan Support for 2017
 
NVIDIA OpenGL 4.6 in 2017
NVIDIA OpenGL 4.6 in 2017NVIDIA OpenGL 4.6 in 2017
NVIDIA OpenGL 4.6 in 2017
 
NVIDIA OpenGL in 2016
NVIDIA OpenGL in 2016NVIDIA OpenGL in 2016
NVIDIA OpenGL in 2016
 
Virtual Reality Features of NVIDIA GPUs
Virtual Reality Features of NVIDIA GPUsVirtual Reality Features of NVIDIA GPUs
Virtual Reality Features of NVIDIA GPUs
 
Migrating from OpenGL to Vulkan
Migrating from OpenGL to VulkanMigrating from OpenGL to Vulkan
Migrating from OpenGL to Vulkan
 
EXT_window_rectangles
EXT_window_rectanglesEXT_window_rectangles
EXT_window_rectangles
 
OpenGL for 2015
OpenGL for 2015OpenGL for 2015
OpenGL for 2015
 
Slides: Accelerating Vector Graphics Rendering using the Graphics Hardware Pi...
Slides: Accelerating Vector Graphics Rendering using the Graphics Hardware Pi...Slides: Accelerating Vector Graphics Rendering using the Graphics Hardware Pi...
Slides: Accelerating Vector Graphics Rendering using the Graphics Hardware Pi...
 
Accelerating Vector Graphics Rendering using the Graphics Hardware Pipeline
Accelerating Vector Graphics Rendering using the Graphics Hardware PipelineAccelerating Vector Graphics Rendering using the Graphics Hardware Pipeline
Accelerating Vector Graphics Rendering using the Graphics Hardware Pipeline
 
NV_path rendering Functional Improvements
NV_path rendering Functional ImprovementsNV_path rendering Functional Improvements
NV_path rendering Functional Improvements
 
OpenGL 4.5 Update for NVIDIA GPUs
OpenGL 4.5 Update for NVIDIA GPUsOpenGL 4.5 Update for NVIDIA GPUs
OpenGL 4.5 Update for NVIDIA GPUs
 
SIGGRAPH Asia 2012: GPU-accelerated Path Rendering
SIGGRAPH Asia 2012: GPU-accelerated Path RenderingSIGGRAPH Asia 2012: GPU-accelerated Path Rendering
SIGGRAPH Asia 2012: GPU-accelerated Path Rendering
 
SIGGRAPH Asia 2012 Exhibitor Talk: OpenGL 4.3 and Beyond
SIGGRAPH Asia 2012 Exhibitor Talk: OpenGL 4.3 and BeyondSIGGRAPH Asia 2012 Exhibitor Talk: OpenGL 4.3 and Beyond
SIGGRAPH Asia 2012 Exhibitor Talk: OpenGL 4.3 and Beyond
 
Programming with NV_path_rendering: An Annex to the SIGGRAPH Asia 2012 paper...
Programming with NV_path_rendering:  An Annex to the SIGGRAPH Asia 2012 paper...Programming with NV_path_rendering:  An Annex to the SIGGRAPH Asia 2012 paper...
Programming with NV_path_rendering: An Annex to the SIGGRAPH Asia 2012 paper...
 
GPU accelerated path rendering fastforward
GPU accelerated path rendering fastforwardGPU accelerated path rendering fastforward
GPU accelerated path rendering fastforward
 
GPU-accelerated Path Rendering
GPU-accelerated Path RenderingGPU-accelerated Path Rendering
GPU-accelerated Path Rendering
 
SIGGRAPH 2012: GPU-Accelerated 2D and Web Rendering
SIGGRAPH 2012: GPU-Accelerated 2D and Web RenderingSIGGRAPH 2012: GPU-Accelerated 2D and Web Rendering
SIGGRAPH 2012: GPU-Accelerated 2D and Web Rendering
 
SIGGRAPH 2012: NVIDIA OpenGL for 2012
SIGGRAPH 2012: NVIDIA OpenGL for 2012SIGGRAPH 2012: NVIDIA OpenGL for 2012
SIGGRAPH 2012: NVIDIA OpenGL for 2012
 

Recently uploaded

The Future of Platform Engineering
The Future of Platform EngineeringThe Future of Platform Engineering
The Future of Platform Engineering
Jemma Hussein Allen
 
Accelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish CachingAccelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish Caching
Thijs Feryn
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
James Anderson
 
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Ramesh Iyer
 
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Product School
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
Kari Kakkonen
 
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 previewState of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
Prayukth K V
 
UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4
DianaGray10
 
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
UiPathCommunity
 
Essentials of Automations: Optimizing FME Workflows with Parameters
Essentials of Automations: Optimizing FME Workflows with ParametersEssentials of Automations: Optimizing FME Workflows with Parameters
Essentials of Automations: Optimizing FME Workflows with Parameters
Safe Software
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
DanBrown980551
 
GraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge GraphGraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge Graph
Guy Korland
 
Leading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdfLeading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdf
OnBoard
 
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Product School
 
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...
Jeffrey Haguewood
 
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Tobias Schneck
 
Key Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdfKey Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdf
Cheryl Hung
 
Elevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object CalisthenicsElevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object Calisthenics
Dorra BARTAGUIZ
 
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualitySoftware Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Inflectra
 
Connector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a buttonConnector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a button
DianaGray10
 

Recently uploaded (20)

The Future of Platform Engineering
The Future of Platform EngineeringThe Future of Platform Engineering
The Future of Platform Engineering
 
Accelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish CachingAccelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish Caching
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
 
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
 
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
 
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 previewState of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
 
UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4
 
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
 
Essentials of Automations: Optimizing FME Workflows with Parameters
Essentials of Automations: Optimizing FME Workflows with ParametersEssentials of Automations: Optimizing FME Workflows with Parameters
Essentials of Automations: Optimizing FME Workflows with Parameters
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
 
GraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge GraphGraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge Graph
 
Leading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdfLeading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdf
 
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...
 
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...
 
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
 
Key Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdfKey Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdf
 
Elevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object CalisthenicsElevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object Calisthenics
 
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualitySoftware Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
 
Connector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a buttonConnector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a button
 

CS 354 Bezier Curves

  • 1. CS 354 Bézier Curves Mark Kilgard University of Texas April 5, 2012
  • 2. CS 354 2 Today’s material  In-class quiz  On procedural methods lecture  Lecture topic  Project 2  Bézier curves
  • 3. CS 354 3 My Office Hours  Tuesday, before class  Painter (PAI) 5.35  8:45 a.m. to 9:15  Thursday, after class  ACE 6.302, just for today, in ENS basement  11:00 a.m. to 12  Randy’s office hours  Monday & Wednesday  11 a.m. to 12:00  Painter (PAI) 5.33
  • 4. CS 354 4 Last time, this time  Last lecture, we discussed  Project 2 on Programmable Shaders  Procedural Methods  L-Systems  Particle systems  Perlin Noise  This lecture  Project 2 discussion  Bézier curves  Project 2 due is due Friday
  • 5. CS 354 5 On a sheet of paper Daily Quiz • Write your EID, name, and date • Write #1, #2, #3, followed by its answer  Multiple choice: A  True or False: Perlin’s stochastic L-system noise function sums up multiple versions of a) repeats the same rule turbulence. forever  List three forces that b) varies the rules a particle system randomly could model c) uses biology to make mountains
  • 6. CS 354 6 Your Mission So Far  You should now have these first two shaders tasks implemented Task 1: apply decal Task 0: roll torus
  • 7. CS 354 7 Procedurally Generating a Torus from a 2D Grid 2D grid over (s,t)∈[0,1] Tessellated torus
  • 8. CS 354 8 GLSL Standard Library Routines You’ll Need for Project 2  texture2D—accesses a 2D texture through a sampler2D and a 2-component texture coordinate set (s,t)  textureCube—access a cube map with a samplerCube and a 3-component texture coordinate set (s,t,r)  normalize—normalizes a vector  cross—computes a cross product of 2 vectors  dot—computes a dot (inner) product of 2 vectors  max—compute the maximum of two values  reflect—compute a reflection vector given an incident vector and a normal vector  vec3—constructor for 3-component vector from scalars  mat3—constructor for 3x3 matrix from column vectors  *—matrix-by-vector or vector-by-matrix multiplication  sin—sine trigonometric function  cos—cosine trigonometric function  pow—raise a number to a power, exponentiation (hint: specular)
  • 9. CS 354 9 Normal Maps Visualized texas_- longhorn2 normal map construction bumps_in normal map construction Hint: dump your normal map computeNormal calls in NormalMap::load stbi_write_tga(buffer, width, height, 3, normal_image);
  • 10. CS 354 10 Other Normal Maps mosaic geforce_etch stripes texas_longhorn bumps_out brick geforce_cell
  • 11. CS 354 11 Coordinate Spaces for Project 2  Parametric space  2D space [0..1]x[0..1] for 2D patch  Object space  Transform the patch’s parametric space into a 3D space containing a torus  Has modeling transformation from object- to world-space  World space  Environment map is oriented in this space  gluLookAt’s coordinates are in this space  Surface space  (0,0,1) is always surface normal direction  Mapping from object space to surface space varies along torus  Perturbed normal from normal map overrides (0,0,1) geometric normal  Eye space  gluLookAt transforms world space to eye space
  • 12. CS 354 12 Making Curves Spline weights used to create curve without computers 
  • 13. CS 354 13 Moving Between Two Points  Given 2 or more points, how can we move between them?  Easy answer: in a straight line  Linear interpolation  p(t) = p0 + t (p1-p0)  Jagged! Can we make something smoother?
  • 14. CS 354 14 Types of curves  Variety of curve formulations  Interpolating  Hermite  Bézier  B-spline  Explore their characteristics 14
  • 15. CS 354 15 Matrix-Vector Form of Cubic 3 p(u ) = ∑ c k u k k =0 c 0  1   u  define c=  c1  u =  2 c 2  u     3  c3  u  then p(u ) = u c = c u T T 15
  • 16. CS 354 16 Interpolating Curve p1 p3 p0 p2 Given four data (control) points p0 , p1 ,p2 , p3 determine cubic p(u) which passes through them Must find c0 ,c1 ,c2 , c3 16
  • 17. CS 354 17 Interpolation Equations apply the interpolating conditions at u=0, 1/3, 2/3, 1 p0=p(0)=c0 p1=p(1/3)=c0+(1/3)c1+(1/3)2c2+(1/3)3c2 p2=p(2/3)=c0+(2/3)c1+(2/3)2c2+(2/3)3c2 p3=p(1)=c0+c1+c2+c2 or in matrix form with p = [p0 p1 p2 p3]T 1 0 0 0   1  1 2  1  3 1         3  3  3  p=Ac A=   2  2 2  2  3 1          3  3  3  1  1 1 1   17
  • 18. CS 354 18 Interpolation Matrix Solving for c we find the interpolation matrix  1 0 0 0   − 5.5 9 − 4.5 1  M I = A =  9 − 22.5 18 − 4.5 −1      − 4.5 13.5 − 13.5 4.5  c=MIp Note that MI does not depend on input data and can be used for each segment in x, y, and z 18
  • 19. CS 354 19 Interpolating Multiple Segments use p = [p0 p1 p2 p3] T use p = [p3 p4 p5 p6]T Get continuity at join points but not continuity of derivatives 19
  • 20. CS 354 20 Blending Functions Rewriting the equation for p(u) p(u)=uTc=uTMIp = b(u)Tp where b(u) = [b0(u) b1(u) b2(u) b3(u)]T is an array of blending polynomials such that p(u) = b0(u)p0+ b1(u)p1+ b2(u)p2+ b3(u)p3 b0(u) = -4.5(u-1/3)(u-2/3)(u-1) b1(u) = 13.5u (u-2/3)(u-1) b2(u) = -13.5u (u-1/3)(u-1) b3(u) = 4.5u (u-1/3)(u-2/3) 20
  • 21. CS 354 21 Blending Functions  These functions are not smooth  Hence the interpolation polynomial is not smooth 21
  • 22. CS 354 22 Interpolating Patch 3 3 p(u , v) = ∑ ∑ cij i u vj i =o j =0 Need 16 conditions to determine the 16 coefficients cij Choose at u,v = 0, 1/3, 2/3, 1 22
  • 23. CS 354 23 Matrix Form Define v = [1 v v2 v3]T C = [cij] P = [pij] p(u,v) = uTCv If we observe that for constant u (v), we obtain interpolating curve in v (u), we can show C=MIPMI p(u,v) = uTMIPMITv 23
  • 24. CS 354 24 Blending Patches 3 3 p(u , v) = ∑ ∑ b (u ) b i j (v ) pij i =o j =0 Each bi(u)bj(v) is a blending patch Shows that we can build and analyze surfaces from our knowledge of curves 24
  • 25. CS 354 25 Other Types of Curves and Surfaces  How can we get around the limitations of the interpolating form  Lack of smoothness  Discontinuous derivatives at join points  We have four conditions (for cubics) that we can apply to each segment  Use them other than for interpolation  Need only come close to the data 25
  • 26. CS 354 26 Hermite Form p’(0) p’(1) p(0) p(1) Use two interpolating conditions and two derivative conditions per segment Ensures continuity and first derivative continuity between segments 26
  • 27. CS 354 27 Equations Interpolating conditions are the same at ends p(0) = p0 = c0 p(1) = p3 = c0+c1+c2+c3 Differentiating we find p’(u) = c1+2uc2+3u2c3 Evaluating at end points p’(0) = p’0 = c1 p’(1) = p’3 = c1+2c2+3c3 27
  • 28. CS 354 28 Matrix Form  p 0  1 0 0 0  p  1 1 1 1 q =  3 =  c p'0  0 1 0 0      p'3 0 1 2 3 Solving, we find c=MHq where MH is the Hermite matrix 1 0 0 0 0 0 1 0 M =  H − 3 3 − 2 − 1    2 −2 1 1 28
  • 29. CS 354 29 Blending Polynomials p(u) = b(u)Tq 2 u 3 − 3 u 2 + 1   − 2 u3 + 3 u 2  b(u ) =  3  u − 2 u2 + u     u −u 3 2  Although these functions are smooth, the Hermite form is not used directly in Computer Graphics and CAD because we usually have control points but not derivatives However, the Hermite form is the basis of the Bézier form 29
  • 30. CS 354 30 Parametric and Geometric Continuity We can require the derivatives of x, y, and z to each be continuous at join points (parametric continuity) Alternately, we can only require that the tangents of the resulting curve be continuous (geometry continuity) The latter gives more flexibility as we have need satisfy only two conditions rather than three at each join point 30
  • 31. CS 354 31 Example  Here the p and q have the same tangents at the ends of the segment but different derivatives  Generate different Hermite curves  This techniques is used in drawing applications 31
  • 32. CS 354 32 Higher Dimensional Approximations  The techniques for both interpolating and Hermite curves can be used with higher dimensional parametric polynomials  For interpolating form, the resulting matrix becomes increasingly more ill-conditioned and the resulting curves less smooth and more prone to numerical errors  In both cases, there is more math operations in rendering the resulting polynomial curves and surfaces 32
  • 33. CS 354 33 Pierre Bézier  French engineer at Renault  Popularized Bézier curves and surfaces  For computer-aided design  Winner: ACM Steven Anson Coons Award for Outstanding Creative Contributions to Computer Graphics  2nd winner, after 1st winner Ivan Sutherland of SketchPad fame
  • 34. CS 354 34 Bézier’s Idea  In graphics and CAD, we do not usually have derivative data  Bézier suggested using the 4 data points as with the cubic interpolating curve to approximate the derivatives in the Hermite form 34
  • 35. CS 354 35 Approximating Derivatives p1 p2 p1 − p0 p3 − p 2 p' (0) ≈ p' (1) ≈ 1/ 3 1/ 3 slope p’(0) slope p’(1) p0 p3 u 35
  • 36. CS 354 36 Equations Interpolating conditions are the same p(0) = p0 = c0 p(1) = p3 = c0+c1+c2+c3 Approximating derivative conditions p’(0) = 3(p1- p0) = c0 p’(1) = 3(p3- p2) = c1+2c2+3c3 Solve four linear equations for c=MBp 36
  • 37. CS 354 37 Bézier Matrix 1 0 0 0 − 3 3 0  0  MB =  3 − 6 3 0    −1 3 − 3 1 p(u) = uTMBp = b(u)Tp blending functions 37
  • 38. CS 354 38 Blending Functions  (1− u)3   2 b(u) = 3u (1− u)  3 u2 (1− u)    u  3 Note that all zeros are at 0 and 1 which forces the functions to be smooth over (0,1) 38
  • 39. CS 354 39 Bernstein Polynomials  The blending functions are a special case of the Bernstein polynomials d! d −k bkd (u ) = u (1 − u ) k k!(d − k )!  These polynomials give the blending polynomials for any degree Bézier form  All zeros at 0 and 1  For any degree they all sum to 1  They are all between 0 and 1 inside (0,1) 39
  • 40. CS 354 40 Convex Hull Property  The properties of the Bernstein polynomials ensure that all Bézier curves lie in the convex hull of their control points  Hence, even though we do not interpolate all the data, we cannot be too far away p1 p2 convex hull Bézier curve p0 p3 40
  • 41. CS 354 41 Bézier Patches Using same data array P=[pij] as with interpolating form 3 3 p (u , v) = ∑∑ bi (u ) b j (v) pij = uT M B P MT v B i =0 j =0 Patch lies in convex hull 41
  • 42. CS 354 42 Analysis  Although the Bézier form is much better than the interpolating form, we have the derivatives are not continuous at join points  Can we do better?  Go to higher order Bézier  More work  Derivative continuity still only approximate  Apply different conditions  Tricky without letting order increase 42
  • 43. CS 354 43 Evaluating Polynomials  Simplest method to render a polynomial curve is to evaluate the polynomial at many points and form an approximating polyline  For surfaces we can form an approximating mesh of triangles or quadrilaterals  Use Horner’s method to evaluate polynomials p(u)=c0+u(c1+u(c2+uc3))  3 multiplications/evaluation for cubic 43
  • 44. CS 354 44 Finite Differences For equally spaced {uk} we define finite differences ∆p k=( k () 0 ( ) p ) u u ∆(k=(k1 pk p ) p +− u () 1 u u ) ( ) (+ ∆ pk ∆ (k1 ∆ (k m u = p +− p ) 1 ()) u ) u () m () m For a polynomial of degree n, the nth finite difference is constant 44
  • 45. CS 354 45 Building a Finite Difference Table p(u)=1+3u+2u2+u3 45
  • 46. CS 354 46 deCasteljau Recursion  We can use the convex hull property of Bézier curves to obtain an efficient recursive method that does not require any function evaluations  Uses only the values at the control points  Based on the idea that “any polynomial and any part of a polynomial is a Bézier polynomial for properly chosen control data” 46
  • 47. CS 354 47 Splitting a Cubic Bézier p0, p1 , p2 , p3 determine a cubic Bézier polynomial and its convex hull Consider left half l(u) and right half r(u) 47
  • 48. CS 354 48 l(u) and r(u) Since l(u) and r(u) are Bézier curves, we should be able to find two sets of control points {l0, l1, l2, l3} and {r0, r1, r2, r3} that determine them 48
  • 49. CS 354 49 Convex Hulls {l0, l1, l2, l3} and {r0, r1, r2, r3}each have a convex hull that that is closer to p(u) than the convex hull of {p0, p1, p2, p3} This is known as the variation diminishing property. The polyline from l0 to l3 (= r0) to r3 is an approximation to p(u). Repeating recursively we get better approximations. 49
  • 50. CS 354 50 Equations Start with Bézier equations p(u)=uTMBp l(u) must interpolate p(0) and p(1/2) l(0) = l0 = p0 l(1) = l3 = p(1/2) = 1/8( p0 +3 p1 +3 p2 + p3 ) Matching slopes, taking into account that l(u) and r(u) only go over half the distance as p(u) l’(0) = 3(l1 - l0) = p’(0) = 3/2(p1 - p0 ) l’(1) = 3(l3 – l2) = p’(1/2) = 3/8(- p0 - p1+ p2 + p3) Symmetric equations hold for r(u) 50
  • 51. CS 354 51 Efficient Form l0 = p0 r3 = p3 l1 = ½(p0 + p1) r1 = ½(p2 + p3) l2 = ½(l1 + ½( p1 + p2)) r1 = ½(r2 + ½( p1 + p2)) l3 = r0 = ½(l2 + r1) Requires only shifts and adds! 51
  • 52. CS 354 52 Every Polynomial is a Bézier Curve We can render a given polynomial using the recursive method if we find control points for its representation as a Bézier curve Suppose that p(u) is given as an interpolating curve with control points q p(u)=uTMIq There exist Bézier control points p such that p(u)=uTMBp Equating and solving, we find p=MB-1MI 52
  • 53. CS 354 53 Conversion Matrix  1 0 0 0   5 3 1  − 6 3 − 2 3  MB MI =  1 −1 Interpolating to Bézier 3 5  − 3 −   3 2 6  0  0 0 1  
  • 54. CS 354 54 Example These two curves were all generated from the same original data using Bézier recursion by converting all control point data to Bézier control points Bézier Interpolating 54
  • 55. CS 354 55 Surfaces Can apply the recursive method to surfaces if we recall that for a Bézier patch curves of constant u (or v) are Bézier curves in u (or v) First subdivide in u Process creates new points Some of the original points are discarded original and discarded original and kept new 55
  • 56. CS 354 56 Second Subdivision 16 final points for 1 of 4 patches created 56
  • 57. CS 354 57 Normals  For rendering we need the normals if we want to shade  Can compute from parametric equations ∂p(u , v) ∂p(u , v) n= × ∂u ∂v  Can use vertices of corner points to determine  OpenGL can compute automatically 57
  • 58. CS 354 58 Utah Teapot Most famous data set in computer graphics Widely available as a list of 306 3D vertices and the indices that define 32 Bézier patches 58
  • 59. CS 354 59 Quadrics Any quadric can be written as the quadratic form pTAp+bTp+c=0 where p=[x, y, z]T with A, b and c giving the coefficients Render by ray casting Intersect with parametric ray p(α)=p0+αd that passes through a pixel Yields a scalar quadratic equation  No solution: ray misses quadric  One solution: ray tangent to quadric  Two solutions: entry and exit points 59
  • 60. CS 354 60 Next Class  Next lecture  Vector graphics and path rendering  Resolution independent 2D graphics  Project 3 to be assigned  Animate a virtual person using motion capture data  Reading  Procedural methods: Chapter 9, 465-499  Curves: Chapter 10, 503-522  Remember Project 2  Shading and lighting with GLSL  Due Friday, April 6th
  • 61. CS 354 61 Thanks • E. Angel and D. Shreiner: Interactive Computer Graphics 6E © Addison-Wesley 2012