Week 12 Tutorial Solutions
1. Explain the advantages and disadvantages of normal mapping (a.k.a. bump
mapping) over adding extra polygons to represent detail.
o
Advantages: Every polygon we add to the scene creates extra
computation at every step of the p
Name:
Student Number:
Signature:
The University Of New South Wales
Sample Exam - Written
Semester 2, 2014
COMP3421 & COMP9415
Computer Graphics
Time allowed: 1 hour
Total number of questions: 7
Total number of marks: 30
Note: Actual nal exam will be 2 hou
Week 3 Tutorial Solutions
Question 1:
Go around the class and talk about why you're interested in graphics. What's the
coolest graphics application you have seen? What would you like to be able to
make?
Question 2:
Suppose we perform the following sequenc
Week 4 Tutorial Solutions
Consider the following OpenGL code:
gl.glMatrixMode(GL2.GL_MODELVIEW);
/ #1
/ Matrix is unknown - whatever value the last piece of
OpenGL code set it to.
gl.glLoadIdentity();
/ #2
/ Matrix is the identity:
/ [ 1 0 0 ]
/ [ 0 1 0 ]
Week 8 Tutorial Solutions
Question 1: 3D Surface of Revolution
Suppose we have a profile of a curve that is a quarter of a circle as defined by the
following function
C(t) = (radius*cos(t),radius*sin(t) For t [0.90]
What would the surface of revolution ar
Week 7 Tutorial Solutions
Question 1:
Consider lighting a quad on the surface of a cylindrical mesh with radius 1. You are
approximating the cylinder with a six-sided prism, as shown below. The position and
distance to the light source and camera are labe
Week 6 Tutorial Solutions
Question 1:
i) The base is pointing inwards.
ii) The first side is pointing outwards
iii) The second side is pointing inwards.
iv) The third side is pointing outwards.
v) The fourth side is pointing outwards.
The image below show
Week 11 Tutorial Solutions
Question 1:
The image below shows an eye ray from the camera hitting a glass sphere.
Draw the reflected and transmitted rays. Use Snell's law to compute refraction
angles, assuming the speed of light in the sphere is 50% of the
Part A
Question 1
We need to use the equation
Id = Kd * Ld * s.m
Where Kd are the diffuse co-efficents of the material (0.4,1,0) and Ld are the diffuse co-efficients of
the light source (0.9,0,0.2).
S is the normalized vector TO the light source so is
s =
Week 9 Tutorial Solutions
Question 1
Consider the scan line algorithm described in class. For the polygon drawn here,
what does the edge list look like? What does the Active Edge List (AEL) look like just
before filling the pixels on scan line 5? What pix
Week 10 Tutorial Solutions
Question 1:
Use de Casteljau's algorithm to generate the point a t = 0.25 on the degree 3
Bezier curve with control points (0,0), (4,16), (20,8), (20,0).
The point is (4.8125, 7.875) as illutrated by the construction
below.
Ques