Computer Science Foundations of Computer Graphics

Similar documents
Computer Science Computer Graphics. Fall Midterm Exam

CS 184, Fall 1996 Midterm #1 Professor: unknown

CS184, Fall 1997 Midterm #1 Professor Brian A. Barksy

CS 184, Fall 1996 Midterm #1 Professor: unknown

file:///c /Documents%20and%20Settings/Jason%20Raftery/My%20Doc...e%20184%20-%20Spring%201998%20-%20Sequin%20-%20Midterm%202.htm

U.C. Berkeley, EECS, Computer Science TAKE HOME EXAM. Your Class Computer Account: DO NOT OPEN THIS INSIDE SODA HALL -- WAIT UNTIL YOU ARE ALONE!

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.

CS184 : Foundations of Computer Graphics Professor David Forsyth Final Examination (Total: 100 marks)

Midterm Exam CS 184: Foundations of Computer Graphics page 1 of 11

U.C. Berkeley, EECS, Computer Science TAKE HOME EXAM. Your Class Computer Account: Your student ID #:

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.

Midterm Exam! CS 184: Foundations of Computer Graphics! page 1 of 13!

CS 4620 Midterm 1. Tuesday 22 October minutes

CS184 : Foundations of Computer Graphics Professor David Forsyth Final Examination

Midterm Exam! CS 184: Foundations of Computer Graphics! page 1 of 14!

FROM VERTICES TO FRAGMENTS. Lecture 5 Comp3080 Computer Graphics HKBU

2D rendering takes a photo of the 2D scene with a virtual camera that selects an axis aligned rectangle from the scene. The photograph is placed into

CS 4620 Midterm, March 21, 2017

Midterm Exam Fundamentals of Computer Graphics (COMP 557) Thurs. Feb. 19, 2015 Professor Michael Langer

Working with Transformations on the Coordinate Plane

CS559 Computer Graphics Fall 2015

Lecture 4. Viewing, Projection and Viewport Transformations

Computer Graphics Prof. Sukhendu Das Dept. of Computer Science and Engineering Indian Institute of Technology, Madras Lecture - 24 Solid Modelling

CS61A, Fall/1999 Midterm #1 Professor Brian Harvey

Triangle Rasterization

CS 130 Final. Fall 2015

3D Polygon Rendering. Many applications use rendering of 3D polygons with direct illumination

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

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

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

Mathematics 308 Geometry. Chapter 9. Drawing three dimensional objects

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

Overview. Pipeline implementation I. Overview. Required Tasks. Preliminaries Clipping. Hidden Surface removal

CS Exam 1 Review Problems Fall 2017

Homework #1. Displays, Alpha Compositing, Image Processing, Affine Transformations, Hierarchical Modeling

Two basic types: image-precision and object-precision. Image-precision For each pixel, determine which object is visable Requires np operations

Homework #2. Hidden Surfaces, Projections, Shading and Texture, Ray Tracing, and Parametric Curves

CS 381 Computer Graphics, Fall 2012 Midterm Exam Solutions. The Midterm Exam was given in class on Tuesday, October 16, 2012.

Graphics and Interaction Rendering pipeline & object modelling

Ū P O K O O T E I K A A M Ā U I U N I V E R S I T Y O F W E L L I N G T O N EXAMINATIONS 2014 TRIMESTER 1 *** WITH SOLUTIONS ***

Topics. From vertices to fragments

Reading. 18. Projections and Z-buffers. Required: Watt, Section , 6.3, 6.6 (esp. intro and subsections 1, 4, and 8 10), Further reading:

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

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

Viewing with Computers (OpenGL)

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

Advanced Lighting Techniques Due: Monday November 2 at 10pm

2D transformations: An introduction to the maths behind computer graphics

CS 184, Fall 1992 MT Solutions Professor Brian A. Barsky

Institutionen för systemteknik

Game Architecture. 2/19/16: Rasterization

Texture Mapping. Texture (images) lecture 16. Texture mapping Aliasing (and anti-aliasing) Adding texture improves realism.

lecture 16 Texture mapping Aliasing (and anti-aliasing)

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

Computer graphic -- Programming with OpenGL I

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

(Refer Slide Time 03:00)

Topics and things to know about them:

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

CHAPTER 1 Graphics Systems and Models 3

For this assignment, you are to expand your renderer from assignment 2 with perspective, a polygon clipper, ambient lighting, and obj file reading.

Homework #1. Displays, Image Processing, Affine Transformations, Hierarchical Modeling

(Refer Slide Time: 00:02:00)

Homework #2. Shading, Projections, Texture Mapping, Ray Tracing, and Bezier Curves

Homework #1. Displays, Image Processing, Affine Transformations, Hierarchical Modeling

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

CS 130 Exam I. Fall 2015

Visibility: Z Buffering

Final Exam Study Guide

Tutorial 4: Texture Mapping Techniques

EXAMINATIONS 2017 TRIMESTER 2

Computer Graphics Prof. Sukhendu Das Dept. of Computer Science and Engineering Indian Institute of Technology, Madras Lecture - 14

CSE528 Computer Graphics: Theory, Algorithms, and Applications

SFU CMPT 361 Computer Graphics Fall 2017 Assignment 2. Assignment due Thursday, October 19, 11:59pm

4.5 VISIBLE SURFACE DETECTION METHODES

CSE328 Fundamentals of Computer Graphics

Graphics for VEs. Ruth Aylett

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

Overview. Viewing and perspectives. Planar Geometric Projections. Classical Viewing. Classical views Computer viewing Perspective normalization

Shadows in Computer Graphics

CS451Real-time Rendering Pipeline

(Refer Slide Time: 00:01:26)

Culling. Computer Graphics CSE 167 Lecture 12

Renderer Implementation: Basics and Clipping. Overview. Preliminaries. David Carr Virtual Environments, Fundamentals Spring 2005

Introduction to Computer Graphics 4. Viewing in 3D

Computer Vision Projective Geometry and Calibration. Pinhole cameras

UNIT 2. Translation/ Scaling/ Rotation. Unit-02/Lecture-01

Lets assume each object has a defined colour. Hence our illumination model is looks unrealistic.

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

Clipping and Scan Conversion

Graphics for VEs. Ruth Aylett

Spatial Data Structures

CSC 305 The Graphics Pipeline-1

Einführung in Visual Computing

Chapter 5. Transforming Shapes

COMP30019 Graphics and Interaction Scan Converting Polygons and Lines

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

Spatial Data Structures

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

CS 4204 Computer Graphics

Transcription:

UNIVERSITY OF CALIFORNIA College of Engineering Department of Electrical Engineering and Computer Sciences Computer Science Division Computer Science 184 - Foundations of Computer Graphics Professor Brian A Barksy TAs: Dan Garcia and Zijiang Yang Fall 1994 - Midterm Exam Relax. You have 80 minutes. You will be graded on the best 4 out of 5 problems. This means you should allocate about 16 minutes per question. Remember to pace yourself. Feel free to use the back of each page for additional answer space. Do not panic. You will have time. Question 1: Scan Conversion [25 points] GOOD SKILL Page 1 In the figure to the right, the grey area represents a dense concentration of edges of a very degenerate polygon. You cannot tell how many edges there are within that region, nor the direction of them. There are two edges we are sure of - these are labeled in bold with the directions specified. There are two topologically distinct regions we care about, X and Y. Each of A-D is worth 3 points for a correct answer, -1 point for a wrong answer, and 0 points if left blank. This is so that a random guessing strategy will, on average, yield 0 overall points. In the future, this will be written [3/-1 points] to indicate the value of a correct/incorrect answer, and will be used for multiple-choice questions. A) B) C) For the Odd/Even rule, is X: (circle one) For the Non-Zero- Winding rule, is X: (circle one) For the Odd/Even rule, is Y: (circle one) IN OUT depends-what's-in-thegrey-region IN OUT depends-what's-in-thegrey-region IN OUT depends-what's-in-thegrey-region file:///c /Documents%20and%20Settings/Jason%20Raft...-%20Fall%201994%20-%20Barsky%20-%20Midterm%201.htm (1 of 8)1/27/2007 5:24:08 PM

D) For the Non-Zero- Winding rule, is Y: (circle one) IN OUT depends-what's-in-thegrey-region Questions E-G concern rotational invariance (i.e. does the category in question remain constant after an arbitrary rotation) E) Is region classification (i.e. whether a region is in or out) by the Non-Zero-Winding rule rotationally invariant? [3/-1 points] (circle one) Yes No Depends on F) We specify the color (R,G,B) for every corner of a polygon (as in one of you assignments). We are then given an ideal system in which each pixel is infinitely small (thus we don't have to worry about all of the nitpicky details that arise due to corners falling between scanlines like special cases for convex corners, incrementing the attributes by that additional wierd factor when first added to the edge_y_start list, etc.). We then color the inside of the polygon using a linear interpolation ("lerping") strategy exactly as in your handout. Think very carefully of different types of polygons and the colors that could be chosen when you answer this question. Is the color inside the polygon rotationally invariant? ("Yes" mean that EVERY polygon's color is rotationally invariant, regardless of the colors and type/size of the polygon, "No" means that NO polygon's color is rotationally invariant, regardless of the colors and type/size of polygon)[6/-2 points] (circle one) Yes No Depends on G) Why? (provide a sketch if it helps)[4 points] Page 2 Question 2: Projections [25 points] The plane of projection is the z=-1 plane. You place your eye at the origin and look toward the negative z-axis. Your view-up vector is the y-azis. There is a line segment up and to your right running from the point (2,1,4) to the point (2,1,-8). For this question ignore clipping. A) Where do the line segment endpoints project on file:///c /Documents%20and%20Settings/Jason%20Raft...-%20Fall%201994%20-%20Barsky%20-%20Midterm%201.htm (2 of 8)1/27/2007 5:24:08 PM

the plane? [10 points] B) Sketch the projection of the line segment on the graph below. [5 points] C) Express, in homogeneous coordinates, the instersection of the line defined by the projector fro the eye to the point (2,1,0) with the plane. [10 points] Answer 2: Projections A) (2,1,4) projects to (,, ) B) (2,1,-8) projects to (,, ) C) The projector from the eye to the point (2,1,0) intersects the plane at the following homogeneous coords: (,,, ) Question 3: Potpourri [25 points] Page 3 A) What is the magnitude of the vector in the second column of a 4 4 homogeneous rotation matrix that rotates 57 degrees about the point (1,3,4)? [3 points] B) At a swap meet you buy a 1000 1000 9 bit framebuffer system with no colortable. You decide to bread up each byte allocated for your pixel the following way: you map 4 of those bits to red, 3 to green and 2 to blue. The DACs for red, green and blue each have 4 bits. When the number of bits of a signal is less than the number of bits of the DAC (as in the green and blue case), you short to ground (binary 0) the upper, most significant pins. What is the maximum number of non-grey-colors you can have with your current scheme? Grey is as we've defined it before, R=G=B. A DAC converts digital information to analog information - e.g. if 0010 were present on the digital input lines, the DAC would output 6 volts, and if 0000were present on the digital input lines, the DAC would output 0 volts. [3 volts] file:///c /Documents%20and%20Settings/Jason%20Raft...-%20Fall%201994%20-%20Barsky%20-%20Midterm%201.htm (3 of 8)1/27/2007 5:24:08 PM

C) Using the numbers from question (B), what is the maximum number of non-grey-colors you would have on the screen at one time if you bought a colortable? [3 points] D) When using the tiling method of damage repair, it is often crucial to choose a reasonable tile size. Student #4 chooses a tile size of 4 pixels/tile and student #1 chooses a tile size of 1 pixel/ tile as shown in the figures to the right. If the user removes the L- shaped object to the right, #1 has to search more tiles than #4, and overall do more work. In the two figures to the right, assume the L-shaped figure is present. Assume we are going to add a graphical primitive which is contained entirely within a single pixel We are going to then remove that primitive and see which student does more work. There are some pixels that force #4 to do more work than #1, and some pizesl that have both #1 and #4 doing the samm amound of work. Shade in any pixel for which work(#4)>work(#1) in the picture on the left, and shade in any pixel for which work(#4)>work(#1) in the picture on the right. [3 points each] E) Given a polygonal dataset of Soda Hall containing over a million polygons, a student suggests using a calligraphic display for it. Give two resons why this would be a bad thing. [4 points] F) In one sentence, how is a 2-D draw or paint application (as discussed in lecture) modal? [3 points] G) What is one reasion someone might want to allow cycles within hierarchies? [3 points] Answer 3: Potpourri A) B) C) D) (please write your answer on the figure above) E 1) E 2) F) G) Question 4: Object Motion Specification [25 points] Page 4 (This question was suggested by a student and has been tweaked a bit) file:///c /Documents%20and%20Settings/Jason%20Raft...-%20Fall%201994%20-%20Barsky%20-%20Midterm%201.htm (4 of 8)1/27/2007 5:24:08 PM

We are interested in spinning a 90 90 square around its azis in a clockwise direction. By FRAME number 90, we would like the square to have completed a full 90 degree rotation. The complicated part is that we'd like the square to remain touching the edge of the original bounding square. In the diagram below, the bounding square is defined by the polygon abcd, and the moving square by a'b'c'd'. Point a' should move between a and b from FRAMEs 0 through 90, and similarly for the other points. Your job is to fill in the proper parameters to the scene description file. We have provided an outline for you, all you need to do is fill in the missing values. The language below is very much GLIDE-like, but we've added some embellishments for this quesiton (e.g. strong identifiers). We do NOT care what happens when FRAME grows larger than 90. A) The point abcd should move at a constant linear velocity. [12 points] B) The square should rotate at a constant angular velocity clockwise as shown above. Keep in mind that in this case, you might want to reference the square (a'b'c'd') without a rotation in other groups. [12 points] C) Are the motions specified by A and B the same? [1 point] Answer 4: Object Motion Specification # Valid transformations in this language are exactly as in GLIDE, i.e. # # transformation-statement ::= translate translationvalue # scale scalevalue # rotate axisvalue anglevalue # <empty-string> # # Also, note that all the values above are triples which can be either # static or dynamic. # # value ::= ( <FLOAT> <FLOAT> <FLOAT> ) # # Dynamic values are surrounded by $ signs. The only dynamic value you should # need for this program is FRAME : an int indicting the current frame number # since the application started running. file:///c /Documents%20and%20Settings/Jason%20Raft...-%20Fall%201994%20-%20Barsky%20-%20Midterm%201.htm (5 of 8)1/27/2007 5:24:08 PM

A,B) Please write your answer on the next page. You may express any numberic computation algebraically. C) Are the two motions the (circle one) Same? Different? Page 5 ## PART A - constant linear velocity ## PART B - constant rotational ## of points. ## velocity of object. point a (-45-45 0) point a (-45-45 0) point b (-45 45 0) point b (-45 45 0) point c ( 45 45 0) point c ( 45 45 0) point d ( 45-45 0) point d ( 45-45 0) ## Here is where you need to fill in ## Here is where you need to fill in ## the arguments to point. ## the arguments to point. point a' ( ) point a' ( ) point b' ( ) point b' ( ) point c' ( ) point c' ( ) point d' ( ) point d' ( ) # We don't care about the surfaces # We don't care about the surfaces face abcd_face (a b c d ) face abcd_face (a b c d ) face abcd'_face (a' b' c' d') face abcd'_face (a' b' c' d') object abcd_obj (abcd_face) object abcd'_obj (abcd'_face) group abcd_group instance abcd_obj object abcd_obj (abcd_face) object abcd'_obj (abcd'_face) group abcd_group instance abcd_obj group abcd'_group group abcd'_group instance abcd'_obj instance abcd'_obj ## Here is where you fill in ## Here is where you fill in ## transformation statements, ## transformation statements, ## if you need any. ## if you need any. file:///c /Documents%20and%20Settings/Jason%20Raft...-%20Fall%201994%20-%20Barsky%20-%20Midterm%201.htm (6 of 8)1/27/2007 5:24:08 PM

group ourworld_group instance abcd_group instance abcd'_group group ourworld_group instance abcd_group instance abcd'_group # Ignore hidden and shadingflag # Ignore hidden and shadingflag render ourworld_group render ourworld_group Question 5: Projections and Football Games [25 points] Cal decides to add TV coverage to their football games. Every once in a while the camera will turn to the crowd and focus on a prticular fan, and the smiling fan will appear on the huge outdoor screen. Most of the time the fan will not be able to figure out from looking at the image of themselves on the big screen where the camera is. Your job is to figure this out given a particular example. You may make the assumption that the camera's view plane normal is parallel to its direction of projection). Your head can be modeled as a unit cube centered at the origin. You ar looking directly down the positive z axis. We've labeled the back face of your head - the lower-left point is a, and b, c and d follow clockwise around the back of your head. Assume that the camera is in a blimp and has a very powerful lens - it is very very far away. Page 6 A) What classification of projection is it? Please be as specific as possible. (e.g. Perspective->Seven Point- >Spamographic->etc.) [3 points] B) Where is the camera? (i.e. What is its COP / DOP as it would have been specified in a descriptor file, e.g. Glide) [3 points] C) If you were to rotate your head to face the camera about two fo the orthogonal axes, what two axes and angles would you rotate around? e.g. Rotate(axis[either x, y, or z], ) [8 points] D) What single axis would lyou rotate about to get the same effective rotation so that you were facing the camera? (ignoring twist - i.e. your final vuv might not be the same, but don't worry about that.). Your answer should be file:///c /Documents%20and%20Settings/Jason%20Raft...-%20Fall%201994%20-%20Barsky%20-%20Midterm%201.htm (7 of 8)1/27/2007 5:24:08 PM

expressed as a single axis. (Hint: that axis will probably not be one of the orthoganol axes) [6 points] E) By how many degrees should the rotation be in question (D)? Please leave the answer in symbolic form. (i.e. don't use a calculator...) [5 points] Answer 5: Projections and Football Games A) B) (,, ) C) First: Rotate (, ) then Rotate (, ) D) (,, ) E) ( ) Page 7 1994 by Brian A. Barsky translated to HTML by Walter Hsiao Eta Kappa Nu (January 1996) file:///c /Documents%20and%20Settings/Jason%20Raft...-%20Fall%201994%20-%20Barsky%20-%20Midterm%201.htm (8 of 8)1/27/2007 5:24:08 PM