Docsity

Midterm Exam for Computer Graphics | CSE 167, Exams of Computer Graphics

Toggle sidebar
bg1
CSE 167: Computer Graphics
Midterm
Winter, 2006
NAME:
A. Vectors (4 points)
Given the following two vectors:
!
a=
3
4
0
!
"
#
#
#
$
%
&
&
&
!!!!!
!
b=
0
1
0
!
"
#
#
#
$
%
&
&
&
Compute the following:
1. The magnitude of
!
a
5
2. The magnitude of
!
b
1
3. The dot product
!
a!
!
b
4
4. The cosine of the angle between
!
a
and
!
b
4/5 AKA .8
B. Normal (1 point)
You are looking down at a flat quadrilateral, defined by four points that all lie in a plane:
5. Write an expression for the normal to this quadrilateral. The normal should be
pointing towards you (out of the paper).
(b-a) X (d-a) / |(b-a) X (d-a)| and similar
a
b
d
pf3
pf4

Partial preview of the text

Download Midterm Exam for Computer Graphics | CSE 167 and more Exams Computer Graphics in PDF only on Docsity!

CSE 167: Computer Graphics

Midterm

Winter, 2006

NAME:

A. Vectors (4 points)

Given the following two vectors:

a =

b =

Compute the following:

  1. The magnitude of

a 5

  1. The magnitude of

b 1

  1. The dot product

a!

b 4

  1. The cosine of the angle between

a and

b 4/5 AKA.

B. Normal (1 point)

You are looking down at a flat quadrilateral, defined by four points that all lie in a plane:

  1. Write an expression for the normal to this quadrilateral. The normal should be

pointing towards you (out of the paper).

(b-a) X (d-a) / |(b-a) X (d-a)| and similar

a

b

c

d

C. Point and vector expressions (6 points)

For each of the following expressions involving points a and b and vectors

u and

v ,

circle “Point” if the result is a point, “Vector” if the result is a vector, or “Invalid” if the

expression is not legal (AKA not affine invariant ). Hint: consider what happens to the w

component in homogeneous coordinates.

  1. a + b Point Vector Invalid

  2. a! b Point Vector Invalid

u!

v Point Vector Invalid

  1. a + 2

u Point Vector Invalid

1 3 a^ +^

2 3 b Point Vector Invalid

1 3 a^ +^

2 3

v Point Vector Invalid

D. Transformation matrix (2 points)

Consider a homogeneous affine transformation matrix M , constructed from columns ! a ,!

b ,!

c !and d^ :

ax bx cx dx

ay by cy dy

az bz cz dz

  1. Write the result of transforming

by M , in terms of

a ,!

b ,!

c !and d. b+d

  1. Suppose this matrix represents the local-to-world transform of an object that is not

changing position, but is spinning about its local z-axis. Which column or columns

(

a ,!

b ,!

c !or d ) of the matrix will not change as the object spins?

c and d

F. Concepts (8 points)

a. Camera Space

b. Image Space

c. Inner Space

d. Normalized View Space

e. Object Space

f. Outer Space

g. Projective Space

h. World Space

  1. Graphics pipeline: Select the correct spaces from above and list them in the order that

we expect each vertex to go through in the traditional transformation process:

Fill in letters here: 1. e 2. h 3. a 4. d 5. b

Match the descriptions to the appropriate concept.

a. A simpler object to make culling tests quicker

b. Aim at an object of interest

c. Draw or don’t draw triangles based on the order of their vertices

d. Makes things farther away appear smaller

e. Only draw objects that are in view

f. Preserves parallel lines

  1. c Backface culling
  2. a Bounding volume
  3. e Frustum culling
  4. b Look-at transform
  5. f Orthographic transform
  6. d Perspective transform
  7. The following pseudocode operations are the steps involved in recursive traversal of a

scene hierarchy. Arrange them in proper order for a drawNode() method.

a. Apply local transform

b. Draw geometry (if any)

c. Recursively draw children (if any)

d. Pop Matrix

e. Push Matrix

drawNode(node) {

e

a

b or c

c or b

d

}