16
Chap. 14 Curves Mathematics for Computer Graphics Applications Seminar for Beginner Summer 2002 Jang Su-Mi 2002-08-07

Chap. 14 Curves Mathematics for Computer Graphics Applications

Embed Size (px)

DESCRIPTION

Chap. 14 Curves Mathematics for Computer Graphics Applications. Seminar for Beginner Summer 2002 Jang Su-Mi 2002-08-07. Parametric Equations of Curve. x= x(u) y= y(u) z= z(u) x(u)= au 2 + bu + c p = p (u) p (u)= [x(u) y(u) z(u)]. Plane Curves(1). - PowerPoint PPT Presentation

Citation preview

Page 1: Chap. 14 Curves Mathematics for Computer Graphics Applications

Chap. 14 CurvesMathematics for Computer Graphics Applications

Seminar for Beginner Summer 2002

Jang Su-Mi2002-08-07

Page 2: Chap. 14 Curves Mathematics for Computer Graphics Applications

Parametric Equations of Curve

x = x(u)y = y(u)z = z(u)x(u) = au2 + bu + c

p = p(u)p(u) = [x(u) y(u) z(u)]

Page 3: Chap. 14 Curves Mathematics for Computer Graphics Applications

Plane Curves(1)

x(u) = axu2 + bxu + cx

y(u) = ayu2 + byu + cy

z(u) = azu2 + bzu + cz

p(u) = au2 + bu + c Algebraic form

Page 4: Chap. 14 Curves Mathematics for Computer Graphics Applications

Plane Curve(2)

3 Point are needed.

p0=[x0 y0 z0] ; u = 0p0.5 =[x0.5 y0.5 z0.5] ; u = 0.5p1=[x1 y1 z1] ; u = 1

Algebraic form 에 대입x0 = cx

x0.5 = 0.25ax + 0.5bx + cx

x1 = ax + bx + cx

y, z 에 대해서도 비슷한 결과

Page 5: Chap. 14 Curves Mathematics for Computer Graphics Applications

Plane Curve(3)

ax = 2x0 - 4x0.5 + 2x1

bx = -3x0 + x0.5 - x1

cx = x0 ax bx cx 에 대하여 푼 것

x(u) = (2x0 - 4x0.5 + 2x1)u2 +(-3x0 + x0.5 - x1)u + x0

y(u), z(u) 도 비슷한 결과

x(u) = (2u2 – 3u +1)x0 + (-4u2 + 4u) x0.5 +(2u2 – u) x1

x0 x0.5 x1 에 대하여 정리

p(u) = (2u2-3u+1)p0+(-4u2+4u)p0.5+(2u2–u)p1

Geometric form

Page 6: Chap. 14 Curves Mathematics for Computer Graphics Applications

Plane Curves(4)

• Matrix Algebra (Algebraic form)p(u) = au2 + bu + c

a[u2 u 1] b = au2 + bu + c

c

U = [u2 u 1]

A = [a b c]T = ax ay az p(u) = UAbx by bz

cx cy cz

Algebraic coefficients

Page 7: Chap. 14 Curves Mathematics for Computer Graphics Applications

Space Curves(5)

• Matrix Algebra (Geometric form)p(u) = (2u2-3u+1)p0+(-4u2+4u)p0.5+(2u2–u)p1

p(u) =[(2u2-3u+1) (-4u2+4u) (2u2–u)] [p0 p0.5 p1]T

F = [(2u2-3u+1) (-4u2+4u) (2u2–u)]P = [p0 p0.5 p1]T = x0 y0 z0

x0.5 y0.5 z0.5

x1 y1 z1

p(u)=FP

Control Point matrix

Geometric Coefficients

Blending function matrix

Page 8: Chap. 14 Curves Mathematics for Computer Graphics Applications

Plane Curves(6)

FP = UA

F = [u2 u 1] 2 -4 2-3 4 -1 M 1 0 0

F = UMUMP = UAMP = AA = MPP = M-1A

Basis transformation matrix

Page 9: Chap. 14 Curves Mathematics for Computer Graphics Applications

Space Curve

• Cubic Polynomials : x(u) y(u) z(u), p(u)

• 4 Points are needed : p0 p1/3 p2/3 p1

• Same process with the Plane curvep(u) = UA Algebraic formp(u) = GP Geometric formG = UN N : basis transformation m

atrixGP = UAUNP = UAA = NP

Page 10: Chap. 14 Curves Mathematics for Computer Graphics Applications

The Tangent Vector

• Use 2 end point, 2 tangents instead of 4 point. (p0 p1 pu

0 pu1 )

• Tangent vectorpu(u) = [ dx(u)i/du dy(u)j/du dz(u)k/du]pu = [xu yu zu]

x(u) = axu3 + bxu2 + cxu + dx

xu = 3axu2 + 2bxu + cx

Page 11: Chap. 14 Curves Mathematics for Computer Graphics Applications

The Tangent Vector

u=0, u=1 대입 x0 x1 xu0 xu

1 에 대하여 정리ax bx cx dx 에 대하여 정리 치환대입 정리

x(u) = (2x0-2x1+ xu0 + xu

1 )u3

+(-3x0 +3 x1-2xu0- xu

1 ) u2

+ xu0u

+ x0

x0 x1 xu0 xu

1 에 대하여 정리x(u) = (2u3-3u2+1)x0

+(-2u3 +3u2) x1

+(u3 -2u2 +u)xu0

+(u3-u2)xu1

p(u) = (2u3-3u2+1)p0 +(-2u3 +3u2)p1

+(u3 -2u2 +u)pu0

+(u3-u2)pu1

F B

Page 12: Chap. 14 Curves Mathematics for Computer Graphics Applications

The Tangent Vector

p(u) = UAp(u) = FBF = UMUMB = UAA = MB

(magnitude of the tangent vector account into)pu

0 = m0t0

pu1 = m1t1

p(u) = (2u3-3u2+1)p0 +(-2u3 +3u2)p1

+(u3 -2u2 +u)m0t0

+(u3-u2)m1t1

Page 13: Chap. 14 Curves Mathematics for Computer Graphics Applications

Blending Function

• F blending Function • G blending Function

Page 14: Chap. 14 Curves Mathematics for Computer Graphics Applications

Reparameterization

• reverse direction

Page 15: Chap. 14 Curves Mathematics for Computer Graphics Applications

Continuity and Composit Curves

• Parametric Continuity : Cn

• Geometric Continuity : Gn

Page 16: Chap. 14 Curves Mathematics for Computer Graphics Applications

Approximating a Conic Curve

• Conic Curves– Hyperbola– Parabola– Ellipse