Download presentation
Presentation is loading. Please wait.
1
BPC: Art and Computation – Spring 2007 Computer Graphics – Lighting and Rendering Erik Brisson ebrisson@bu.edu
2
BPC: Art and Computation – Spring 20072 Given P = (1.0, 2.0) P = (1.0, 2.0) T = (5.0, 1.0) T = (5.0, 1.0) Compute P’ P’ = P + T = (1.0, 2.0) + (5.0, 1.0) P’ = P + T = (1.0, 2.0) + (5.0, 1.0) = (1.0+5.0, 2.0+1.0) = (1.0+5.0, 2.0+1.0) = (6.0, 3.0) = (6.0, 3.0) Translation vector
3
BPC: Art and Computation – Spring 20073 Rotation by angle Define a rotation matrix M = / cos sin \ \ -sin cos / \ -sin cos / Then P’ = P M Example: = 30 degrees. P = (3.5, 2.0) Then cos = 0.87, sin = 0.50 P’ = (3.5, 2.0) / 0.87 0.50 \ \ -0.50 0.87 / \ -0.50 0.87 / = (3.5*0.87+2.0*-0.50, 3.5*0.50+2.0*0.87) = (3.5*0.87+2.0*-0.50, 3.5*0.50+2.0*0.87) = (2.05, 3.49) = (2.05, 3.49)
4
BPC: Art and Computation – Spring 20074 Scaling by Sx, Sy Define a scaling matrix M = / Sx 0 \ \ 0 Sy / \ 0 Sy / Then P’ = P M Example: Sx = 0.5, Sy = 2.0 P’ = (2.0, 2.0) / 0.5 0.0 \ \ 0.0 2.0 / \ 0.0 2.0 / = (2.0*0.5+2.0*0.0, 2.0*0.0+2.0*2.0) = (2.0*0.5+2.0*0.0, 2.0*0.0+2.0*2.0) = (1.0, 4.0) = (1.0, 4.0)
5
BPC: Art and Computation – Spring 20075 P’ = P + T T = P’ – P Example, T = P’ – P = (6.0, 3.0) – (1.0, 2.0) = (5.0, 1.0) = (5.0, 1.0) Vector as difference of points
6
BPC: Art and Computation – Spring 20076 Back to lighting V_eye = P_eye - P V_light = P_light - P V_eye = (4, 1, 10) - (5, 2, 3) = (-1, -1, 7) V_light = (3, 7, 2) – (5, 2, 3) = (-2, 5, -1)
7
BPC: Art and Computation – Spring 20077 Unit shading vectors n = surface normal vector u_light = unit vector to light point u_eye = unit vector to view point
8
BPC: Art and Computation – Spring 20078 Ray casting
9
BPC: Art and Computation – Spring 20079 Ray cast, with light
10
BPC: Art and Computation – Spring 200710 Ray tracing
11
BPC: Art and Computation – Spring 200711 Scan-conversion idea
12
BPC: Art and Computation – Spring 200712 Scan-conversion of polygon
13
BPC: Art and Computation – Spring 200713 Shading at vertices, interpolation
14
BPC: Art and Computation – Spring 200714 Flat shading vs Gouraud shading
15
BPC: Art and Computation – Spring 200715 Shading ambient diffuse specular
16
BPC: Art and Computation – Spring 200716 Obscuration Some objects block others Sort back-to-front Z-buffer algorithm
17
BPC: Art and Computation – Spring 200717 C.G. concept - texture map
18
BPC: Art and Computation – Spring 200718 C.G. example - texture map
19
BPC: Art and Computation – Spring 200719 Texture map full +
20
BPC: Art and Computation – Spring 200720 The quest for photorealism
21
BPC: Art and Computation – Spring 200721 Alternative rendering techniques
22
BPC: Art and Computation – Spring 200722 Alternative rendering techniques
23
BPC: Art and Computation – Spring 200723 3D object photography http://www.royalalbertamuseum.ca/vexhibit/virtcoll/ index.asp
24
BPC: Art and Computation – Spring 200724 Panoramic photography
25
BPC: Art and Computation – Spring 200725 Other techniques
26
BPC: Art and Computation – Spring 200726 Other techniques, laser scanning
27
BPC: Art and Computation – Spring 200727 Now we can model, transform, illuminate, and render doughnuts
Similar presentations
© 2025 SlidePlayer.com Inc.
All rights reserved.