Download presentation
Presentation is loading. Please wait.
Published byWalter Black Modified over 9 years ago
1
CS 445: Introduction to Computer Graphics David Luebke University of Virginia Review
2
Admin l Course evaluations: please do during class today (available on Toolkit)
3
Math l Mathematical foundations –Vector arithmetic –Affine spaces: points, vectors, scalars –Parametric representation of a line/ray/segment –Dot product, cross product –Matrix-matrix and matrix-vector arithmetic
4
Display technologies l CRTs –Underlying technology –Vector vs. raster –Framebuffer, pixel, scanline, rasterize l LCDs –Underlying technology –Pros & cons l Other – don’t need to know details –Plasma display –OLED
5
Rendering pipeline l Know the various stages: –Transforms n Modeling n Camera n Projection –Illuminate –Clip –Homogeneous divide –Rasterize l Be able to reason about which stages go where
7
Transformations l Modeling transforms –Object world coords –Common xforms: n Translate n Rotate n Scale (uniform vs. nonuniform) –Composing xforms n Multiplying matrices – know the correct order! n Be able to compose a rotation matrix about an arbitrary axis n Be able to compose rotation & translation matrices
8
Transformations l Homogeneous coordinates –Homogeneous coordinate akin to a scale factor –Homogeneous points vs. vectors –Enables translation, projection l Projection transforms –Uses the homogeneous coordinate –Be ready to reason about simple projection xforms
9
OpenGL l Specifying transforms –Understand how to use the matrix stacks n GL_MODELVIEW n GL_PROJECTION –Understand the principles of hierarchical transforms n Nest xforms n Functions shouldn’t have side effects –Understand the concept of a scene graph
10
Clipping l 2D: Cohen-Sutherland –Outcodes & how to use them –Clipping a line segment to an edge l 3D: Sutherland-Hodgeman l Clipping in the graphics pipeline
11
Rasterization l Line rasterization –DDA –Optimization strategies l Triangle rasterization –Edge walking –Edge equations l Polygon rasterization –Parity test –Active edge table
12
Color l Physiology of the eye –Cornea, lens, retina –Photoreceptors n Rods (low light, luminance) vs. cones (high light levels, color) n Color-sensitivity of cones: S, M, L (B, G, R) n Density: fovea (high spatial resolution, all cones) vs. periphery (low spatial resolution, largely rods) –Metamers: different spectra with the same perceptual response n E.g., a monochromatic orange light (spectral spike) vs. combinations of red, green, tiny bit of blue: same perceived color! –Color gamuts and CIE chromaticity diagram
13
The Human Visual System l The human visual system has four types of sensors: rods and S, M, and L cones ν 1 0.1 0.01 10 100 rods cones L M S sensitivity Courtesy Nathaniel Hoffman
14
l Rods are the most sensitive –Used in weak illumination (scotopic) conditions –Sensitivity peaks at cyan (blue-green) –Only one kind: monochromatic vision l Cones enable color vision –Used in strong illumination (photopic) conditions –Total sensitivity peaks at yellow-green –Three kinds: trichromatic vision The Human Visual System Courtesy Nathaniel Hoffman
15
The Human Visual System l Trichromatic vision enables us to somewhat sense the spectral distribution ν 0.5 0.25 1 L M S sensitivity 0.1 Courtesy Nathaniel Hoffman
16
Metamers l A spectral power distribution is an infinite-dimensional signal. l Since we perceive color only as a three-dimensional signal, there is an infinite number of different spectral power distributions which map onto the same perceived color. l These are known as metamers. Courtesy Nathaniel Hoffman
17
Metamers 700nm 600nm 500nm 400nm 470nm 480nm white spectral locus more blue more redmore green more yellow Courtesy Nathaniel Hoffman
18
Metamers 700nm 600nm 500nm 400nm 470nm 480nm white spectral locus more blue more redmore green more yellow Courtesy Nathaniel Hoffman
19
Metamers 700nm 600nm 500nm 400nm 470nm 480nm white spectral locus more blue more redmore green more yellow Courtesy Nathaniel Hoffman
20
Metamers 700nm 600nm 500nm 400nm 470nm 480nm white spectral locus more blue more redmore green more yellow Courtesy Nathaniel Hoffman
21
Lighting l Illumination models –Global vs. local illumination models –Empirical vs. physically based l Know and understand the Phong model: –Local, empirical, implemented in OpenGL –Ambient, diffuse, and specular terms l Shading: flat vs. smooth (Gouraud) vs. Phong
22
Phong Lighting: OpenGL Implementation l The final Phong model as we studied it: l OpenGL variations: –Every light has an ambient component –Surfaces can have “emissive” component to simulate glow n Added directly to the visible reflected intensity n Not actually a light source (does not illuminate other surfaces)
23
Visibility in the small l Painter’s algorithm l Z-buffer l BSP trees: organize all of space (hence partition) into a binary tree –Preprocess: overlay a binary tree on objects in the scene –Runtime: correctly traversing this tree enumerates objects from back to front –Idea: divide space recursively into half-spaces by choosing splitting planes n Splitting planes can be arbitrarily oriented n Notice: nodes are always convex
24
Visibility in the large l View-frustum culling l Cells & portals (architectural/urban models) –Cells form the basic unit of PVS –Create an adjacency graph of cells –Starting with cell containing eyepoint, traverse graph, rendering visible cells –A cell is only visible if it can be seen through a sequence of portals n So cell visibility reduces to testing portal sequences for a line of sight… l Occlusion query (modern hardware)
25
Texture mapping l Establishing correspondences (parameterization): texture coordinates l Interpolating texture coordinates in screen space during rasterization l Texture map antialiasing: –know MIP-mapping, be aware of others –Related to antialiasing subject: prefiltering l Applications of texture mapping: –Bump mapping, gloss mapping, displacement mapping, light mapping
26
Modern GPUs l Programmable GPUs –Programmable vertex & fragment engines –Render to texture –Floating point precision l Programming model: stream computing –Registers zeroed out, no accumulators across vertices/fragments –Lends itself to efficient parallel implementation –Cg language
27
GPGPU l Trends: GPUs fast, getting faster faster l Approach: data as textures, computational kernels as fragment programs l Advance simulation step-by-step using render-to-texture
28
Ray tracing l Basic algorithm: recursive ray tracing –Reflection –Refraction –Shadows l Ray-primitive intersection –Be able to reason about common primitives, or figure out a new intersection test l Acceleration structures
29
Antialiasing l Reason at a high level about what aliasing is and how we can prevent/mitigate it –Basic signal theory behind Nyquist limit –Supersampling: pros and cons –Prefiltering: pros and cons –Stochastic supersampling: high freqs noise, not aliases
30
LOD l Basic concept (easy) l Discrete vs. continuous vs. view-dependent : pros and cons
31
Shadows l Basic concept of shadow volumes –Stencil buffer –Problem case: clipping
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.