Introduction to Computer Graphics Ed Angel Professor Emeritus of Computer Science Founding Director, Arts, Research, Technology and Science Laboratory University of New Mexico Angel and Shreiner: Interactive Computer Graphics 6E © Addison-Wesley 2012 1 Overview • These lectures are for CS/EECE 412 Computer Graphics at the University of New Mexico - Senior/graduate elective • Based on Ed Angel and Dave Shreiner, Interactive Computer Graphics, A Top-down Approach with OpenGL (Sixth Edition), AddisonWesley, 212 • These lectures cover Chapters 1-5 in detail and survey Chapters 7-11 • Each ppt file corresponds to one 50 minute lecture (a few require a bit more time) Angel and Shreiner: Interactive Computer Graphics 6E © Addison-Wesley 2012 2 Contact Information angel@cs.unm.edu www.cs.unm.edu/~angel Angel and Shreiner: Interactive Computer Graphics 6E © Addison-Wesley 2012 3 Objectives • Broad introduction to Computer Graphics - Software - Hardware - Applications • Top-down approach • Shader-Based OpenGL compatible with - OpenGL 3.1 (and later) - Open GL ES 2.0 - webGL Angel and Shreiner: Interactive Computer Graphics 6E © Addison-Wesley 2012 4 Prerequisites • Good programming skills in C (or C++) • Basic Data Structures - Linked lists - Arrays • Geometry • Simple Linear Algebra Angel and Shreiner: Interactive Computer Graphics 6E © Addison-Wesley 2012 5 Requirements • 3 Assigned Projects - Simple - Interactive - 3D • Term Project - You pick • See www.cs.unm.edu/~angel under Book Support for other info Angel and Shreiner: Interactive Computer Graphics 6E © Addison-Wesley 2012 6 Resources • Can run OpenGL on any system - Windows: check graphics card properties for level of OpenGL supported - Linux - Mac: need extensions for 3.1 equivalence • Get GLUT from web if needed - Provided on Macs - freeglut available on web • Get GLEW from web • WebGL: most newer browsers Angel and Shreiner: Interactive Computer Graphics 6E © Addison-Wesley 2012 7 References • www.opengl.org - Standards documents - Sample code • The OpenGL Programmer’s Guide (the Redbook) 7th Edition • The definitive reference • Mixes 3.0 and 3.1 • OpenGL Shading Language, 3rd Edition • OpenGL ES 2.0 Programming Guide • All Addison-Wesley Professional Angel and Shreiner: Interactive Computer Graphics 6E © Addison-Wesley 2012 8 Web Resources • www.cs.unm.edu/~angel/SFX_GRAPHICS • www.cs.unm.edu/~angel/BOOK • www.cs.unm.edu/~angel/CS433 - Pre 3.1 version • Additional materials available to instructors through their Addison-Wesley representatives Angel and Shreiner: Interactive Computer Graphics 6E © Addison-Wesley 2012 9 Outline: Part 1 • Part 1: Introduction • Text: Chapter 1 • Lectures 1-3 - What is Computer Graphics? - Applications Areas - History - Image formation - Basic Architecture Angel and Shreiner: Interactive Computer Graphics 6E © Addison-Wesley 2012 10 Outline: Part 2 • Part 2: Basic OpenGL • Text: Chapter 2 • Lectures 4-11 - Architecture - GLUT - Simple programs in two and three dimensions - Basic shaders and GLSL - Interaction Angel and Shreiner: Interactive Computer Graphics 6E © Addison-Wesley 2012 11 Outline: Part 3 • Part 3: Three-Dimensional Graphics • Text: Chapters 3-5 • Lectures 12-22 - Geometry - Transformations - Homogeneous Coordinates - Viewing - Lighting and Shading Angel and Shreiner: Interactive Computer Graphics 6E © Addison-Wesley 2012 12 Outline: Part 4 • Part 5: Implementation • Text: Chapter 6 • Lectures: 23-25 - Approaches (object vs image space) - Implementing the pipeline - Clipping - Line drawing - Polygon Fill - Display issues (color) Angel and Shreiner: Interactive Computer Graphics 6E © Addison-Wesley 2012 13 Outline: Part 5 • Part 4: Discrete Methods • Text: Chapter 7 • Lectures 26-30 - Buffers - Texture Mapping - Shader Applications - Compositing and Transparency Angel and Shreiner: Interactive Computer Graphics 6E © Addison-Wesley 2012 14 Outline: Part 6 • Part 6: Hierarchy and Procedural Methods • Text: Chapters 8-9 • Lectures: 31-34 • Tree Structured Models - Traversal Methods - Scene Graphs - Particle Systems Angel and Shreiner: Interactive Computer Graphics 6E © Addison-Wesley 2012 15 Outline: Part 7 • Part 7: Curves and Surfaces • Text: Chapter 10 • Lectures: 35-38 Angel and Shreiner: Interactive Computer Graphics 6E © Addison-Wesley 2012 16 Outline: Part 8 • Part 8: Advanced Rendering • Text: Chapter 11 • Lectures: 39-40 Angel and Shreiner: Interactive Computer Graphics 6E © Addison-Wesley 2012 17 Extra Lectures • Marching Squares • Virtual Trackball • Environment Mapping • Shadows • Fractals • Display Issues • Bump Mapping • Sampling and Aliasing • Reflection and Transmission Angel and Shreiner: Interactive Computer Graphics 6E © Addison-Wesley 2012 18