Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736:...

24
Computing & Information Sciences Kansas State University Friday, 18 Jan 2008 CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18 January 2008 William H. Hsu Department of Computing and Information Sciences, KSU KSOL course pages: http://snipurl.com/1y5gc / http://snipurl.com/1ybv6 Course web site: http://www.kddresearch.org/Courses/Spring-2008/CIS736 Instructor home page: http://www.cis.ksu.edu/~bhsu Reading for Next Class: Syllabus and Course Intro Chapter 1, Eberly (2006) 3D Game Engine Design, 2 e (Introduction to) Computer Graphics Course Organization and Survey

Transcript of Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736:...

Page 1: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Lecture 00 of 42

Friday, 18 January 2008

William H. Hsu

Department of Computing and Information Sciences, KSU

KSOL course pages: http://snipurl.com/1y5gc / http://snipurl.com/1ybv6

Course web site: http://www.kddresearch.org/Courses/Spring-2008/CIS736

Instructor home page: http://www.cis.ksu.edu/~bhsu

Reading for Next Class:

Syllabus and Course Intro

Chapter 1, Eberly (2006) 3D Game Engine Design, 2e

(Introduction to) Computer GraphicsCourse Organization and Survey

Page 2: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Lecture Outline

Course Information: Format, Exams, Resources, Assignments, Grading

Overview

Topics covered

What is computer graphics?

Applications

Brief Tour of Computer Graphics

A case study and some demos

Survey of rendering and animation systems

Applications to computer-aided design (CAD), manufacturing (CAM), and

engineering (CAE)

Brief Tour of Visualization Systems

Information, data, and scientific visualization

Focus on informational graphics

Page 3: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Course Administration

Course Pages (KSOL): http://snipurl.com/1y5gc / http://snipurl.com/1y5ih

Class Web Page: www.kddresearch.org/Courses/Spring-2008/CIS736

Instructional E-Mail Addresses – Best Way to Reach Instructor [email protected] (always use this to reach instructor and TA)

[email protected] (everyone; substitute 636 for 736 for Intro to CG)

Instructor: William Hsu, Nichols 213 Office phone: +1 785 532 7905; home phone: +1 785 539 7180

IM: AIM/MSN/YIM hsuwh/rizanabsith, ICQ 28651394/191317559, Google banazir

Office hours: after class Mon/Wed/Fri; other times by appointment

Graduate Teaching Assistant: Jing Xia Office location: Nichols 213a

Office hours: to be announced on class web board

Grading Policy Hour exams: 10% each (in-class, with notes); final (open-book): 25%

Machine problems, problem sets (6 of 8): 18%; term project: 20%

Paper reviews (2): 4%; class participation: 6% (HW, Q&A); labs 7%

Page 4: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Class Resources

Course Content Management System (CMS) http://www.kddresearch.org/Courses/Spring-2008/CIS736

Lecture notes (MS PowerPoint 97-2003, PDF)

Homeworks (MS PowerPoint 97-2003, PDF)

Exam and homework solutions (MS PowerPoint 97-2003, PDF)

Class announcements (students’ responsibility) and grade postings

Course Notes at Copy Center (Required)

Mailing List (Automatic): [email protected] Homework/exams (before uploading to CMS, KSOL), sample data, solutions

Class participation

Project info, course calendar reminders

Dated research announcements (seminars, conferences, calls for papers)

LISTSERV Web Archive http://listserv.ksu.edu/archives/cis736-l.html

Stores e-mails to class mailing list as browsable/searchable posts

Page 5: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Course Overview

Graphics Systems and Techniques Main emphasis: shaders, lighting, mappings (textures, etc.) in OpenGL

Photorealistic rendering and animation (Maya 2008, Blender; Ogre)

2-D, 3-D models: curves, surfaces, visible surface identification, illumination

Special topics: global illumination (ray tracing, radiosity), particle systems, fractals, scientific visualization (sciviz) and information visualization (infoviz)

Operations Surface modeling, mapping

Pipelines for display, transformation, illumination, animation

Computer Graphics (CG): Duality with Computer Vision

Visualization and User Interfaces

Applications CAD/CAM/CAE: object transformations, surface/solid modeling, animation

Entertainment: 3-D games, photorealistic animation, etc.

Analysis: info visualization, decision support, intelligent displays

Page 6: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Why Computer Graphics?

Developing Computational Capability Rendering: synthesizing realistic-looking, useful, or interesting images

Animation: creating visual impression of motion

Image processing: analyzing, transforming, displaying images efficiently

Better Understanding of Data, Objects, Processes through Visualization Visual summarization, description, manipulation

Virtual environments (VR), visual monitoring, interactivity

Human-computer intelligent interaction (HCII): training, tutoring, analysis,

control systems

Time is Right Recent progress in algorithms and theory

Rapidly emergence of new I/O (display and data acquisition) technologies

Available computational power, improving price-performance-ratio of hardware

Growth and interest of graphics industries (e.g., games, entertainment,

computer-aided design, visualization in science and business)

Page 7: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Image Synthesis Pipeline

GraphicsDatabaseEditing

GraphicsDatabase

ModelingTransformation

ViewingOperation

DisplayTraversal

• Visible-Surface Determination• Scan Conversion• Shading / Illumination

Image

Front-End

(Geometry Processing)

Back-End

(Rasterization)

Page 8: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

HypermediaUser Interfaces

Hypermedia Database format (similar to hypertext)

Provides display-based access to (internetworked) multimedia (text, image,

audio, video, etc.) documents

Virtual Environments Immersion: interactive training, tutoring systems

Entertainment hypermedia

Visualization and Computer-Aided Design and Engineering (CAD/CAE) Visualization: scientific, data/information, statistics

User interfaces for CAD/CAE/CAM/CASE

NCSA Data to Knowledge (D2K) &

Text to Knowledge (T2K):

http://alg.ncsa.uiuc.edu/do/tools/d2k

Visual programming systems for high-

performance knowledge discovery

in databases (KDD)© 2004 National Center for Supercomputing Applications

Page 9: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Analytic Geometry

Art and Graphic Design

Cognitive Science

Computer Engineering

Engineering Design

Education

Film

Human Factors

Linear Algebra

Numerical Analysis

Relevant Topic Areas

ComputerGraphics

(CG)

Parametric EquationsConics

Polygon Rendering

LayoutCG Design

Visualization

Rendering HardwareVR Systems

Portable/Embedded CG

Color/Optical ModelsCG/Vision DualityInterface Design

CADCAE / CASE

CAM

Immersive TrainingTutoring Interfaces

AnimationLarge-Scale CG

User ModelingErgonomic Interfaces, I/O

TransformationsChange of Coordinate Systems

Surface ModelingPhysically-Based Modeling

Stat/Info Visualization

Page 10: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Curve and Surface Modelingin Computer-Aided Design (CAD)

12 3

4

5

6

78

http://www.geocities.com/SiliconValley/Lakes/2057/nurbs.html

Page 11: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Computer-Generated Animation (CGA)

Wall-E© 2008 Disney/Pixar

Kung-Fu Panda© 2008 DreamWorksAnimation SKG

Meet the Robinsons© 2007 Disney/Pixar

Shrek (2001)Shrek 2 (2004)

Shrek the Third (2007)© DreamWorks Animation SKG

Toy Story (1995)Toy Story 2 (1999)Toy Story 3 (2010)

© Disney/Pixar

Happy Feet© 2006Warner Brothers

Ratattouille© 2007 Disney/Pixar

Luxo Jr.© 1986 Pixar Animation Studios

Page 12: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Fractal Systems

http://sprott.physics.wisc.edu/fractals.htm

Page 13: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Information Visualization

Visible Decisions SeeIT © 1999 VDI http://www.advizorsolutions.com

Page 14: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Design Choices and Issuesin Computer Graphics

Completed Design

DetermineDisplay Objective

Visualize PhysicalObjects

MonitorProcess

InteractivelyAnalyze

Data / Documents

Determine Objectives ofGraphics System

Entertainment DecisionSupport Education

ControlInterface

Determine and ImplementRendering Pipeline

Shaded-PolygonRendering

Ray TracingRadiosity and

Polygon Shading

Determine RepresentationsIn Graphics Database

Solid GeometricModel Wireframe /

Polygon Mesh NURBSFractalSystem

Page 15: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Math Review for CIS 636

Overview: First Month (Weeks 2-5 of Course) Review of mathematical foundations of CG: analytic geometry, linear algebra

Line and polygon rendering

Matrix transformations

Graphical interfaces

Line and Polygon Rendering (Week 3) Basic line drawing and 2-D clipping

Bresenham’s algorithm

Follow-up: 3-D clipping, z-buffering (painter’s algorithm)

Matrix Transformations (Week 4) Application of linear transformations to rendering

Basic operations: translation, rotation, scaling, shearing

Follow-up: review of standard graphics libraries (e.g., OpenGL)

Graphical Interfaces Brief overview

Survey of windowing environments (MFC, Java AWT)

Page 16: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Online Recorded Lectures for CIS 636

Introduction to Computer Graphics Project Topics for CIS 636

Computer Graphics Basics (8) 1. Mathematical Foundations – week of Mon 21 Jan 2008

2. Rasterizing and 2-D Clipping – week of Mon 28 Jan 2008

3. OpenGL Primer 1 of 3 – week of Mon 28 Jan 2008

4. Detailed Introduction to 3-D Viewing – week of Mon 04 Feb 2008

5. OpenGL Primer 2 of 3 – week of Mon 11 Feb 2008

6. Polygon Rendering – week of Mon 18 Feb 2008

7. OpenGL Primer 3 of 3 – week of Mon 03 Mar 2008

8. Visible Surface Determination – week of Mon 10 Mar 2008

Recommended Background Reading for CIS 636

Shared Lectures with CIS 736 (Computer Graphics) Regular in-class lectures (35) and labs (7)

Guidelines for paper reviews – week of Mon 25 Feb 2008

Preparing term project presentations and demos for graphics – April

Page 17: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Online Recorded Lectures for CIS 736

Computer Graphics Project Topics for CIS 736

Advanced Topics in Computer Graphics (8) 1. Filters for Texturing – week of Mon 28 Jan 2008

2. More Mappings – week of Mon 18 Feb 2008

3. Advanced Lighting Models – week of Mon 17 Mar 2008

4. Advanced Ray-Tracing – week of Mon 25 Feb 2008

5. Advanced Ray-Tracing, concluded – week of Mon 24 Mar 2008

6. Global Illumination: Photon Maps (Radiosity) – week of Mon 31 Mar 2008

7. More on Scientific, Data, Info Visualization – week of Mon 21 Apr 2008

8. Terrain – week of Mon 11 Feb 2008

Recommended Background Reading for CIS 636

Shared Lectures with CIS 636 (Computer Graphics) Regular in-class lectures (35) and labs (7)

Guidelines for paper reviews – week of Mon 25 Feb 2008

Preparing term project presentations and demos for graphics – April

Page 18: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Background Expected

Both Courses Proficiency in C/C++ or strong proficiency in Java and ability to learn

Strongly recommended: matrix theory or linear algebra (e.g., Math 551)

At least 120 hours for semester (up to 150 depending on term project)

Textbook: 3D Game Engine Design, Second Edition (2006), Eberly

Angel’s OpenGL: A Primer recommended

CIS 636 Fresh background in precalculus: Algebra 1-2, Analytic Geometry

Linear algebra basics: matrices, linear bases, vector spaces

Watch background lectures

CIS 736 Computer Graphics Recommended: first course in graphics (background lectures as needed)

OpenGL experience helps

Read up on shaders and shading languages

Watch advanced topics lectures; see list before choosing project topic

Page 19: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Textbook and Recommended Books

Required Textbook

Eberly, D. H. (2006). 3D Game Engine Design: A Practical Approach to Real-Time Computer Graphics, second edition. San Francisco, CA: Morgan Kauffman.

Recommended References

Angel, E. O. (2007). OpenGL: A Primer, third edition. Reading, MA: Addison-Wesley. [2nd edition on reserve]

Shreiner, D., Woo, M., Neider, J., & Davis, T. (2007). OpenGL® Programming Guide: The Official Guide to Learning OpenGL®, Version 2.1, sixth edition.

[“The Red Book”: use 5th ed. or later]

2nd edition (OK to use) 3rd edition

1st edition (outdated) 2nd edition

Page 20: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

References and Outside Reading

Page 21: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Syllabus [1]:First Half of Course

Page 22: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Syllabus [2]:Second Half of Course

Page 23: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Summary

This course is a lot of work Reading: Eberly 2e – big book, like Foley et al.

Programming assignments (3): expect to spend 10+ hours on each

Written assignments (3): about 6-10 hours

Term project: at least 20 hours (people have spent up to 50 or more)

… but it can also be fun Visible results

Nifty algorithms, high-performance hardware

“Putting it all together”: very interdisciplinary field

Decent job market for people with right development skills, ideas

Applicable to many other areas of CS and IT

Emphasis “Polygons to pixels pipeline”: viewing, VSD, lighting, shading, texturing

Other topics to be covered: animation, curves and surfaces, collisions

Brief survey of: ray tracing, visualization and color, fractals

Page 24: Computing & Information Sciences Kansas State University Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics Lecture 00 of 42 Friday, 18.

Computing & Information SciencesKansas State University

Friday, 18 Jan 2008CIS 636/736: (Introduction to) Computer Graphics

Terminology

Computer Graphics: Digital Synthesis, Manipulation of Visual Content Graphics Problems (see “Computer Graphics”, Wikipedia)

Geometry: representation and processing of surfaces Animation: representation and manipulation of motion Rendering: computationally reproducing appearance of light in scenes Imaging:

Different Approaches to Graphics Raster versus vector Sample-based versus geometry-based

Purpose of Graphics Entertainment – games, visual effects in movies and television Communications – advertising, journalism Modeling / simulation – displaying events via graphical user interfaces (GUIs) Visualization – displaying events for analysis and understanding

Dual Problem: Inverse Input and Output Graphics (rendering): geometry to sample (image) Vision: sample to geometry