Introduction to Computer Graphics. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2011

Similar documents
CSE 167: Introduction to Computer Graphics. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2013

CSE 167: Introduction to Computer Graphics Lecture #2: Coordinate Transformations

CSE 167: Introduction to Computer Graphics. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2016

CSE 167: Lecture #8: Lighting. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2011

CSE 167: Introduction to Computer Graphics Lecture #4: Coordinate Systems

Today. Rendering algorithms. Rendering algorithms. Images. Images. Rendering Algorithms. Course overview Organization Introduction to ray tracing

CSE 167: Lecture #4: Vertex Transformation. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2012

Exercise Max. Points Total 80

CSE 167: Lecture #5: Rasterization. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2012

CSE 167: Lecture #8: GLSL. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2012

CSCD18: Computer Graphics. Instructor: Leonid Sigal

CSE 167: Introduction to Computer Graphics Lecture #7: Lights. Jürgen P. Schulze, Ph.D. University of California, San Diego Spring Quarter 2015

Today. Rendering algorithms. Rendering algorithms. Images. Images. Rendering Algorithms. Course overview Organization Introduction to ray tracing

CIS 581 Interactive Computer Graphics

Exercise Max. Points Total 90

CSE 167: Introduction to Computer Graphics Lecture #5: Rasterization. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2015

CSE 167: Introduction to Computer Graphics Lecture #4: Vertex Transformation

CS535: Interactive Computer Graphics

CSE 167: Introduction to Computer Graphics Lecture #11: Visibility Culling

Computer Graphics Disciplines. Grading. Textbooks. Course Overview. Assignment Policies. Computer Graphics Goals I

CS380: Computer Graphics Introduction. Sung-Eui Yoon ( 윤성의 ) Course URL:

CSE 167: Introduction to Computer Graphics Lecture #10: View Frustum Culling

CSE 167: Introduction to Computer Graphics Lecture #3: Projection. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2016

CSE 167: Lecture 11: Textures 2. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2011

The Graphics Pipeline and OpenGL I: Transformations!

CSE 167: Introduction to Computer Graphics Lecture #19: Wrapping Up. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2017

CSE 167: Introduction to Computer Graphics Lecture #6: Lights. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2014

CIS 581 Interactive Computer Graphics (slides based on Dr. Han-Wei Shen s slides) Requirements. Reference Books. Textbook

CSE 167: Lecture #15: Procedural Modeling. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2012

CSE 167: Lecture #17: Procedural Modeling. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2011

CS559: Computer Graphics. Lecture 1 Introduction Li Zhang University of Wisconsin, Madison

CSE 167: Introduction to Computer Graphics Lecture #9: Visibility. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2018

Course Producer. Prerequisites. Textbooks. Academic integrity. Grading. Ming Chen. Same office hours as TA. The Hobbit: The Desolation of Smaug (2013)

Computer Graphics Coursework 1

CS5620 Intro to Computer Graphics

Welcome to CS 4/57101 Computer Graphics

Lahore University of Management Sciences. CS 452 Computer Graphics

Lahore University of Management Sciences. CS 452 Computer Graphics

CSE 167: Introduction to Computer Graphics Lecture #8: Scene Graph. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2015

Lecture 0 of 41: Part A Course Organization. Introduction to Computer Graphics: Course Organization and Survey

CSE 167: Introduction to Computer Graphics Lecture #3: Projection. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2013

Computer Science 175. Introduction to Computer Graphics lib175 time: m/w 2:30-4:00 pm place:md g125 section times: tba

Topic 0. Introduction: What Is Computer Graphics? CSC 418/2504: Computer Graphics EF432. Today s Topics. What is Computer Graphics?

Computer Graphics (CS 543) Lecture 1 (Part 1): Introduction to Computer Graphics

I expect to interact in class with the students, so I expect students to be engaged. (no laptops, smartphones,...) (fig)

CSE 167: Introduction to Computer Graphics Lecture #6: Lights. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2016

CSE 167: Introduction to Computer Graphics Lecture #3: Coordinate Systems

CSCI-6962 Advanced Computer Graphics

3D GRAPHICS. design. animate. render

0. Introduction: What is Computer Graphics? 1. Basics of scan conversion (line drawing) 2. Representing 2D curves

EF432. Introduction to spagetti and meatballs

IMAGE-BASED RENDERING AND ANIMATION

Overview. Computer Graphics CSE 167

The Graphics Pipeline and OpenGL I: Transformations!

COMP Preliminaries Jan. 6, 2015

CSE 167: Introduction to Computer Graphics Lecture #18: More Effects. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2016

CSE 167: Introduction to Computer Graphics Lecture 12: Bézier Curves. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2013

Outline. Intro. Week 1, Fri Jan 4. What is CG used for? What is Computer Graphics? University of British Columbia CPSC 314 Computer Graphics Jan 2013

Intro. Week 1, Fri Jan 4

Programming Game Engines ITP 485 (4 Units)

CS451Real-time Rendering Pipeline

EE , GPU Programming

CS 410: Computer Graphics

EF432. Introduction to spagetti and meatballs

CSE 167: Lecture #7: Color and Shading. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2011

ce Hours: MW 12:30 PM 1:30 PM (till 12/12/18), or by appointment

COMPUTER GRAPHICS CS

CSCE 441 Computer Graphics Fall 2018

CS4620/5620 Introduction to Computer Graphics

Computer graphics 2: Graduate seminar in computational aesthetics

Game Mathematics. (12 Week Lesson Plan)

CSE 167: Lecture #17: Volume Rendering. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2012

CSE 167: Introduction to Computer Graphics Lecture #5: Visibility, OpenGL

CS380: Computer Graphics Introduction. Sung-Eui Yoon ( 윤성의 ) Course URL:

CSE 167: Introduction to Computer Graphics Lecture 11: Scene Graph 2. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2013

Cornell CS4620 Fall 2011!Lecture Kavita Bala (with previous instructors James/Marschner) Cornell CS4620 Fall 2011!Lecture 1.

Computer Graphics CS 543 Lecture 1 (Part I) Prof Emmanuel Agu. Computer Science Dept. Worcester Polytechnic Institute (WPI)

CS354 Computer Graphics Introduction. Qixing Huang Januray 17 8h 2017

Course Web Site ENGN2501 DIGITAL GEOMETRY PROCESSING. Tue & Thu Barus&Holley 157

Computer Science 426 Midterm 3/11/04, 1:30PM-2:50PM

Real-Time Universal Capture Facial Animation with GPU Skin Rendering

Luxo Jr. Plan. Team. Movies. Why Computer Graphics? Introduction to Computer Graphics. Pixar Animation Studios, 1986 Director: John Lasseter

CS4621/5621 Fall Computer Graphics Practicum Intro to OpenGL/GLSL

Computer Graphics. Instructor: Oren Kapah. Office Hours: T.B.A.

Goals. Course Staff. Demo: Surreal (HW 3) Entertainment. Foundations of Computer Graphics (Spring 2012) Why Study 3D Computer Graphics?

Karen Liu associate professor at School of Interactive Computing. Murali Varma graduate student at School of Interactive Computing

CS4621/5621 Fall Computer Graphics Practicum Final Projects. Professor: Kavita Bala Instructor: Nicolas Savva

EE 4702 GPU Programming

Problem Max. Points Total 80

Advanced Graphics

Advanced Computer Graphics: Non-Photorealistic Rendering

CSE 167: Introduction to Computer Graphics Lecture #6: Colors. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2013

Lecturer Athanasios Nikolaidis

Goals. Computer Graphics (Fall 2008) Course Outline. Course Outline. Course Outline. Demo: Surreal and Crazy World (HW 3)

Welcome to 6.837! Welcome to all students: Plan for today: Introductions. Why study graphics? Team 18 s final project from 6.

CSE 167: Introduction to Computer Graphics Lecture #8: Textures. Jürgen P. Schulze, Ph.D. University of California, San Diego Spring Quarter 2016

CS559 Computer Graphics Fall 2015

CSE 167: Introduction to Computer Graphics Lecture #5: Projection. Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2017

CS 6958 LECTURE 4 INTRO TO GRAPHICS GEOMETRY

CSE 167: Introduction to Computer Graphics Lecture #9: Scene Graph. Jürgen P. Schulze, Ph.D. University of California, San Diego Spring Quarter 2016

Transcription:

CSE 167: Introduction to Computer Graphics Jürgen P. Schulze, Ph.D. University of California, San Diego Fall Quarter 2011

Today Course overview Course organization Vectors and Matrices 2

What is computer graphics Applications: Movie, TV special effects Video games Scientific visualization GIS (Geographic Information Systems) Medical visualization Industrial design Simulation Communication Etc. 3

What is computer graphics? Rendering Modeling Animation 4

Rendering Synthesis of a 2D image from a 3D scene description Rendering algorithm interprets data structures that represent the scene in terms of geometric primitives, textures, and lights 2D image is an array of pixels Red, green, blue values for each pixel Different objectives Photorealistic Interactive Artistic 5

Photorealistic rendering Physically-based simulation of light, camera Shadows, realistic illumination, multiple light bounces Slow, minutes to hours per image Special effects, movies CSE168: Rendering Algorithms 6

Photorealistic rendering 7

Interactive rendering Produce images within milliseconds Using specialized hardware, graphics processing units (GPUs) Standardized APIs (OpenGL, DirectX) Often as photorealistic as possible Hard shadows, fake soft shadows, only single bounce of light Games CSE167 8

Interactive rendering 9

Live Demo NVIDIA Geoforms: Real-Time Rendering http://nzone.nvidia.com/object/nzone_geoforms_downloads.html 10

Artistic rendering Stylized Artwork, illustrations, data visualization 11

Artistic rendering 12

Modeling Creating 3D geometric data The model or the scene By hand Autodesk (Maya, AutoCAD), LightWave 3D, Free software Blender Not as easy to use as Notepad 13 Maya Screenshot

Modeling Basic 3D models consist of array of triangles Each triangle stores 3 vertices Each vertex contains xyz position Color Etc. 14

Modeling Procedural: by writing programs Scanning real-world objects 15

Modeling Procedural tree Scanned statue Procedural city 16

Animation Deforming or editing the geometry Change over time Faces, articulated characters, CSE169: Computer Animation (not offered this year) 17

Animation 18

Physics simulation 19

Video SIGGRAPH 2011 Technical Papers: http://www.youtube.com/watch?v=jk9eee3rskm Blender Demo Reel 2011: http://www.youtube.com/watch?v=qbze8joo7_0 20

Today Course overview Course organization Vectors and Matrices 21

Course Staff Instructor Jürgen Schulze, Ph.D. Lecturer in CSE, Research Scientist at Calit2 Teaching Assistants Gregory Long, CSE graduate student Jorge Schwarzhaupt, CSE graduate student 22

Course Organization Lecture Tue/Thu, 2:00pm-3:20pm, Peterson Hall 104 Homework Grading Fridays (only on due dates) at 1:30pm, CSE lab 260 Instructor Office Hour Tue 3:30pm-4:30pm, Atkinson Hall room 2125 Office Hours in Lab 260 Gregory Long: Tue 12-1p, Wed 4:30-6:30p, Thu 5-7p Jorge Schwarzhaupt: Tue 1-2p, Wed 3:30-5:30p, Thu 5-7p 23

Prerequisites Familiarity with Linear algebra C++ Object oriented programming 24

In this class Rendering 3D models Camera simulation Interactive viewing Lighting Shading Modeling Triangle meshes Parametric surfaces Applying linear algebra, C++, OpenGL Foundation for advanced graphics courses (eg, CSE168, CSE 190 on shader programming) 25

Ted Go to http://ted.ucsd.edu and select CSE167 Log in with your Active Directory account Used for discussion board and grades 26

Course Web Site URL: http://ivl.calit2.net/wiki/index.php/cse_167_fall_2011 Class schedule Lecture slides Textbooks Announcements Homework assignments Grading information (grades on Ted) 27

Textbooks Both textbooks are recommended, not required Peter Shirley: Fundamentals of Computer Graphics, any edition (Google Books has full text version) OpenGL Programming Guide Older versions available on-line 28

Programming Projects 7 programming assignments First and last are group projects Find assignments and schedule on Ted Base code (for Windows and Linux) and documentation on Ted Use EBU3B 2xx labs or your own PC/laptop Individual assistance by TAs during lab office hours Turn in by demonstration to TA during homework grading hours on Fridays. Demonstration can be done on lab PC or personal computer. Homework projects are due by Fridays 1:30pm. Late submissions possible with point deduction. 29

Written Tests Two in-class written tests. Closed book, handwritten index card is permitted. Midterm exam: Thu 10/27, 2:00pm-3:20pm, Peterson Hall 104 Final exam: Thu 12/08, 3:00pm-6:00pm, location TBD 30

Grading Homework Projects 1-6: 10% each Written exams: 10% each Final project: 20% Late submission policy for homework projects: 75% of original grade if you present your project within seven days of the due date 31

Today Course overview Course organization Vectors and Matrices 32

Vectors Direction and length in 3D Vectors can describe Difference between two 3D points Speed of an object Surface normals (directions perpendicular to surfaces) Normal vector 33 Surface normals Surface

Vector arithmetic using coordinates a = ax ay az b = bx by bz ax + bx ax bx a + b = ay + by az + bz a b = ay by az bz ax a= ay az sax sa= say saz where s is a scalar 34

Vector Magnitude The magnitude (length) of a vector is: v 2 = v 2 x + v 2 2 y + v z v = v 2 x + v 2 2 y + v z A vector with length of 1.0 is called unit vector We can also normalize a vector to make it a unit vector Unit vectors are often used as surface normals v v 35

Dot Product a b = a i b i a b = a x b x + a y b y + a z b z a b = a b cosθ 36

Angle Between Two Vectors a b = a b cosθ cosθ = a b a b b θ = cos 1 a b a b a 37

Cross Product a b is a vector perpendicular to both a and b, in the direction defined by the right hand rule a b = a b sinθ a b = area of parallelogram ab a b = 0 if a and b are parallel (or one or both degenerate) 38

Cross product 39

Sample Vector Class in C++ class Vector3 { public: float x,y,z; Vector3() {x=0.0; y=0.0; z=0.0;} Vector3(float x0,float y0,float z0) {x=x0; y=y0; z=z0;} void set(float x0,float y0,float z0) {x=x0; y=y0; z=z0;} void add(vector3 &a) {x+=a.x; y+=a.y; z+=a.z;} void add(vector3 &a,vector3 &b) {x=a.x+b.x; y=a.y+b.y; z=a.z+b.z;} void subtract(vector3 &a) {x-=a.x; y-=a.y; z-=a.z;} void subtract(vector3 &a,vector3 &b) {x=a.x-b.x; y=a.y-b.y; z=a.z-b.z;} void negate() {x=-x; y=-y; z=-z;} void negate(vector3 &a) {x=-a.x; y=-a.y; z=-a.z;} void scale(float s) {x*=s; y*=s; z*=s;} void scale(float s,vector3 &a) {x=s*a.x; y=s*a.y; z=s*a.z;} float dot(vector3 &a) {return x*a.x+y*a.y+z*a.z;} void cross(vector3 &a,vector3 &b) {x=a.y*b.z-a.z*b.y; y=a.z*b.x-a.x*b.z; z=a.x*b.y-a.y*b.x;} float magnitude() {return sqrt(x*x+y*y+z*z);} void normalize() {scale(1.0/magnitude());} }; 40

Matrices Rectangular array of numbers Square matrix if m = n In graphics often m = n = 3; m = n = 4 41

Matrix Addition 42

Multiplication With Scalar 43

Matrix Multiplication 44

Matrix-Vector Multiplication 45

Identity Matrix 46

Matrix Inverse If a square matrix M is non-singular, there exists a unique inverse M -1 such that 47

OpenGL Matrices Vectors are column vectors Column major ordering Matrix elements stored in array of floats float M[16]; Corresponding matrix elements: 48

Announcements Next Lecture Tue 9/27 at 2pm Topic: Homogeneous Coordinates Preparation: Review three dimensional vector/matrix calculations Homework Introduction (optional): Introduction to base code and homework assignment #1: Gregory Long, CSE lab 260, Monday Sept 26 th, 3pm Homework assignment #1 due Friday, Sept 30 49