Temporal Resolution. Flicker fusion threshold The frequency at which an intermittent light stimulus appears to be completely steady to the observer

Similar documents
Scanline Rendering 1 1/42

Rendering. Converting a 3D scene to a 2D image. Camera. Light. Rendering. View Plane

Drawing in 3D (viewing, projection, and the rest of the pipeline)

Overview. By end of the week:

3D Rendering and Ray Casting

Shadows in the graphics pipeline

3D Rendering and Ray Casting

Lecture 4. Viewing, Projection and Viewport Transformations

Drawing in 3D (viewing, projection, and the rest of the pipeline)

Drawing in 3D (viewing, projection, and the rest of the pipeline)

CS451Real-time Rendering Pipeline

Raycasting. Chapter Raycasting foundations. When you look at an object, like the ball in the picture to the left, what do

The exam begins at 2:40pm and ends at 4:00pm. You must turn your exam in when time is announced or risk not having it accepted.

Computer Graphics and Visualization. Graphics Systems and Models

Computer Vision Project-1

Notes on Assignment. Notes on Assignment. Notes on Assignment. Notes on Assignment

Scene Modeling for a Single View

Computer Graphics - Chapter 1 Graphics Systems and Models

VTU QUESTION PAPER SOLUTION UNIT -1 INTRODUCTION

Modeling Light. On Simulating the Visual Experience

Today. Rendering pipeline. Rendering pipeline. Object vs. Image order. Rendering engine Rendering engine (jtrt) Computergrafik. Rendering pipeline

Introduction to 3D Concepts

Ray Tracing Basics I. Computer Graphics as Virtual Photography. camera (captures light) real scene. photo. Photographic print. Photography: processing

Scanline Rendering 2 1/42

Three-Dimensional Viewing Hearn & Baker Chapter 7

Ray Tracer I: Ray Casting Due date: 12:00pm December 3, 2001

COMP environment mapping Mar. 12, r = 2n(n v) v

Ray Tracer Due date: April 27, 2011

lecture 18 - ray tracing - environment mapping - refraction

Introduction: The Nature of Light

Advanced Computer Graphics Transformations. Matthias Teschner

CS201 Computer Vision Lect 4 - Image Formation

3D Viewing. CMPT 361 Introduction to Computer Graphics Torsten Möller. Machiraju/Zhang/Möller

Computer Graphics. Chapter 1 (Related to Introduction to Computer Graphics Using Java 2D and 3D)

Drawing Fast The Graphics Pipeline

COSC579: Scene Geometry. Jeremy Bolton, PhD Assistant Teaching Professor

Models and Architectures

Computer Graphics. Illumination and Shading

Real-Time Shadows. Last Time? Textures can Alias. Schedule. Questions? Quiz 1: Tuesday October 26 th, in class (1 week from today!

I N T R O D U C T I O N T O C O M P U T E R G R A P H I C S

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

Triangle Rasterization

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

Three Main Themes of Computer Graphics

COMP 175 COMPUTER GRAPHICS. Ray Casting. COMP 175: Computer Graphics April 26, Erik Anderson 09 Ray Casting

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

LIGHTING AND SHADING

3D GRAPHICS. design. animate. render

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

Institutionen för systemteknik

3D Viewing. Introduction to Computer Graphics Torsten Möller. Machiraju/Zhang/Möller

The Traditional Graphics Pipeline

Scene Modeling for a Single View

Real-Time Shadows. Last Time? Schedule. Questions? Today. Why are Shadows Important?

Rendering. Generate an image from geometric primitives II. Rendering III. Modeling IV. Animation. (Michael Bostock, CS426, Fall99)

RASTERISED RENDERING

Prof. Feng Liu. Fall /19/2016

Illumination and Shading

Scene Modeling for a Single View

3D Rendering. Course Syllabus. Where Are We Now? Rendering. 3D Rendering Example. Overview. Rendering. I. Image processing II. Rendering III.

Viewing COMPSCI 464. Image Credits: Encarta and

Graphics Hardware and Display Devices

Introduction to Computer Graphics with WebGL

CHAPTER 1 Graphics Systems and Models 3

CS 498 VR. Lecture 18-4/4/18. go.illinois.edu/vrlect18

Single-view 3D Reconstruction

Models and The Viewing Pipeline. Jian Huang CS456

CPSC GLOBAL ILLUMINATION

Models and Architectures. Ed Angel Professor of Computer Science, Electrical and Computer Engineering, and Media Arts University of New Mexico

Soft shadows. Steve Marschner Cornell University CS 569 Spring 2008, 21 February

3D Graphics for Game Programming (J. Han) Chapter II Vertex Processing

Lecture 13: Reyes Architecture and Implementation. Kayvon Fatahalian CMU : Graphics and Imaging Architectures (Fall 2011)

Topics and things to know about them:

Lecture 3 Sections 2.2, 4.4. Mon, Aug 31, 2009

CS354 Computer Graphics Ray Tracing. Qixing Huang Januray 24th 2017

Ulf Assarsson Department of Computer Engineering Chalmers University of Technology

Reading on the Accumulation Buffer: Motion Blur, Anti-Aliasing, and Depth of Field

Computer Graphics 7: Viewing in 3-D

Computer Graphics (CS 543) Lecture 10: Normal Maps, Parametrization, Tone Mapping

Movie: For The Birds. Announcements. Ray Tracing 1. Programming 2 Recap. Programming 3 Info Test data for part 1 (Lines) is available

CS602 Midterm Subjective Solved with Reference By WELL WISHER (Aqua Leo)

Consider a partially transparent object that is illuminated with two lights, one visible from each side of the object. Start with a ray from the eye

Real-Time Shadows. Last Time? Today. Why are Shadows Important? Shadows as a Depth Cue. For Intuition about Scene Lighting

Perspective Mappings. Contents

C P S C 314 S H A D E R S, O P E N G L, & J S RENDERING PIPELINE. Mikhail Bessmeltsev

Ray Casting. Connelly Barnes CS 4810: Graphics

UNIT 2 2D TRANSFORMATIONS

Viewing. Part II (The Synthetic Camera) CS123 INTRODUCTION TO COMPUTER GRAPHICS. Andries van Dam 10/10/2017 1/31

Pipeline Operations. CS 4620 Lecture Steve Marschner. Cornell CS4620 Spring 2018 Lecture 11

graphics pipeline computer graphics graphics pipeline 2009 fabio pellacini 1

6.837 Introduction to Computer Graphics Quiz 2 Thursday November 20, :40-4pm One hand-written sheet of notes allowed

MITOCW MIT6_172_F10_lec18_300k-mp4

- Rasterization. Geometry. Scan Conversion. Rasterization

2D/3D Geometric Transformations and Scene Graphs

graphics pipeline computer graphics graphics pipeline 2009 fabio pellacini 1

Orthogonal Projection Matrices. Angel and Shreiner: Interactive Computer Graphics 7E Addison-Wesley 2015

Computer Graphics Shadow Algorithms

Visibility: Z Buffering

Viewing. Announcements. A Note About Transformations. Orthographic and Perspective Projection Implementation Vanishing Points

Blue colour text questions Black colour text sample answers Red colour text further explanation or references for the sample answers

Transcription:

Temporal Resolution Flicker fusion threshold The frequency at which an intermittent light stimulus appears to be completely steady to the observer For the purposes of presenting moving images (animations), at least 16 Hz is needed for humans to not interpret them as a series of still pictures Movies are recorded at 24 frames per second TV broadcasts at 30 frames per second Even though motion may seem to be continuous at 24-30 frames per second, the brightness may still seem to flicker Movies are refreshed at 48 or 72 Hz (each frame is projected 2 or 3 times) Computer monitors refresh at 60-80 Hz (or more) independent of what is displayed TV uses interlacing to approximate 60 Hz, showing half of each frame at a time 1/38

Scanline Rendering 1 2/38

Scanline Renderer A virtual environment/world that mimics the real world but cheats a bit for efficiency, using what we know about light and our eye e.g., from the last lecture Set up a virtual camera somewhere in the virtual world, and point it in some direction Put a virtual piece of film (that stores RGB values) into the camera, and take a picture This film data is your final image Place some objects in front of the camera, including a floor/ground, some walls, ceiling/sky, etc. How do we represent these virtual objects? Virtual geometry? Geometric Modeling This is actually a two step process: (1) Make the objects (2) Place the objects in the scene Making objects is itself a two step process: build the geometry & then paint it Don t forget to put some lights into the scene, so it s not completely dark Finally, snap the picture --- that is, code needs to emit light from the virtual light sources, bounce it off the geometry, and follow it into the camera onto the film 3/38

Homework This week s homework and sample code (along with the lectures today and Thursday) is designed to help you learn your way around in a scanline renderer We re using OpenGL (there are other options ) It provides real time feedback so you can experiment with stuff and learn by doing By way of comparison, the ray tracer will be A LOT SLOWER Next week, we ll focus on Geometric Modeling (in the lectures, sample code, and homework) to help you create and obtain geometry that you can put into your virtual scenes Make sure to keep the basic concepts from last Thursday s lecture in mind as we progress we ll assume familiarity with that stuff, as we make various assumptions 4/38

Cameras 5/38

Human Eye Rendering a computer generated image is similar in spirit to how you see real world images Light is emitted from light sources, absorbed and reflected off of objects, and enters the pupil of the eye 6/38

Pupil Without a pupil, light would scatter everywhere and would not make a coherent image on the cones of the eye With a pupil, light makes a coherent image on the cones Cameras, similarly, have an aperture 7/38

Cameras Cameras work very much like the eye Light from the environment is bent by the lens array to make an image on the film Digital cameras record this image as RGB values Our scanline renderer will use a virtual camera 8/38

Pinhole Camera Simplified theoretical construct, but similar to an actual eye or camera Eyes and cameras can t have VERY small holes, because that limits the amount of entering light and diffracts/bends the light 9/38

Pinhole Camera Light leaving any point travels in straight lines We only care about the lines that hit the pinhole (a single point) Infinite depth of field i.e., everything is in focus (no blur) An upside down image is formed by the intersection of these lines with an image plane More distant objects subtend smaller visual angles and appear smaller Objects occlude the objects behind them 10/38

OpenGL Camera OpenGL uses a pinhole camera. However, the image plane (i.e. the film) is placed in front of the pinhole, so that the image is not upside down The frustum is the volume of the view (shown in blue below) Notice the front and back clipping planes! The image plane (i.e. the film) is the clipping plane closest to the camera 11/38

Helpful Hints Get very familiar with the OpenGL camera Do not put the camera too close to your objects (fisheye look) Set it up like a real world scene Significant/severe deductions for poor camera placement, fisheye, etc. (because your image will look terrible) Make sure your near and far clipping plane have enough space between them to contain your scene Do not set the near clipping plane at the camera aperture! Make sure your objects are inside the viewing frustum Etc. Etc. This is a real time system, use the interactivity to your benefit 12/38

Question 1 (short & long form) Where would you like to take your CG picture? Outside? Day or Night? Park? Mountains? City or Country? What Season? Lake? Ocean? Underwater? Space? Skydiving? Inside? Theatre? Classroom? Dorm Room? Living Room? Bathroom? Basement? Attic? Etc.? 13/38

Geometric Models 14/38

Triangles Stanford Bunny 69,451 triangles David, Digital Michelangelo Project 28,184,526 vertices, 56,230,343 triangles 15/38

Why Triangles? It s easy to break convex polygons into triangles As a result, can focus on optimizing the hardware/software implementation of only one primitive (i.e. optimize for triangles) Triangles have some nice properties Guaranteed to be planar (unlike quadrilaterals) Guaranteed to have a well-defined interior There exists a well-defined method for interpolating values in the triangle interior (barycentric interpolation) Etc 16/38

Geometric Modeling Next week 17/38

Arranging your scene 18/38

Transformations Transform every point: (x,y,z ) = T(x,y,z) P = T(P) Moves triangles (& thus geometry) http://youtube/6g3o60o5u7w Create objects (or parts of objects) in convenient coordinates, and then transform into the scene later Make multiple copies (even different sizes) of a single object Connect kinematics of linkages/skeletons for characters/robots 19/38

Matrix Representation Efficiency: can combine a sequence of transforms into a single transform (since matrix multiplication is associative): P = A ( B ( C ( D ( P ) ) ) ) = ( A B C D ) P = M P Compute the composite matrix M once and then apply it to many points 20/38

Hierarchical Transforms M 1 transforms the teapot from its model space to the table s model space M 2 transforms the table from its model space to world space M 2 M 1 transforms the teapot from its model space to world space 21/38

Lines Map to Lines Parametric line: Transform all the points on the line Get a new line connecting the transformed points 22/38

Question 2 (short & long form) What sorts of objects will be in your scene? Ground? Sky? Planets? Moon? Sun? Trees? Leaves? Mountains? Snow? Buildings? Sidewalk? Roads? Cars? Humans? Animals? Barns? Walls? Floors? Rugs? Ceiling? Fans? Chairs? Desks? People? Pets? Your favorite CA? A dart board? Etc.? 23/38

Rotations 24/38

Rotation glm::angleaxis(angle, vec3(ax, ay, ax)) 25/38

2D Rotation Matrix The columns of the matrix are the new locations of the x and y axes So, set the columns to the desired new locations of the x and y axes Rotation matrix = 3D is similar 26/38

Translations 27/38

Translation What does a translation matrix look like? use homogeneous coordinates glm::translate(current, vec3(tx, ty, tz)) 28/38

Homogeneous Coordinates The homogeneous coordinates of a 3D point (x, y, z) are (xw, yw, zw, w) Conversely, the position (x, y, z) of a 3D point can be calculated from homogeneous coordinates by dividing by w (xw/w, yw/w, zw/w) Setting w=1, gives the homogeneous coordinates used for translations: a 3D point (x, y, z) becomes (x, y, z, 1) 29/38

2D Rotation Matrix A 2D point becomes (x, y, 1), so we need a 3x3 matrix in order to represent a 2D rotation This is done by adding an extra row and column of (0, 0, 1) Similarly, 3D rotation matrices are expressed via a 4x4 matrix 30/38

2D Translation Matrix 3D is similar 31/38

Vectors In homogeneous coordinates, vectors are represented using w=0 instead of w=1 Thus translation does not affect vectors, as desired 1 0 t x 0 1 t y x y = x y 0 0 1 0 0 The vectors still rotate properly though 32/38

Composite Transformations 33/38

Rotate 45 degrees about the point (1,1)... R(45) T(-1,-1) T(1,1) T(1,1) R(45) T(-1,-1) 34/38

Be Careful, Order Matters T(1,1) R(45) R(45) T(1,1) Matrix multiplication is NOT commutative The rightmost transform is applied to the points first 35/38

Hint Place an object at the center of the target coordinate system (scene or an intermediate) Rotate the object into the desired orientation Translate the object in order to place it in the target coordinate system (scene or an intermediate) 36/38

Question 3 (long form only) 3. Find a web site with advice on 3D art, and summarize some of what you learned by reading the site (about 500 words). E.g. 30 top examples of 3D art https://www.creativebloq.com/3d/inspiring-examples-3d-art-12121523 37/38

Question 3 (short form only) Looking for Artists: 3A. Name/Email 3B. Best Advice 38/38