Answers

1.a)             P_A=(1,1)  (+0.5 mark)

            P_B=(1/3,2) (+0.5 mark)

            P_C=(5/2,1/4) (+0.5 mark)

 

1.b) There are several transformations.  One possible transformation is:

M_BC=Shear(y,1/2)Scale(3/2,1/2)Rot(x,180)Rot(z,-90)Trans(-4/3,-7)  (+ 1 mark)

 

M_BC=[0     -1/2   7/2]  

             [-3/2  1/4   1/4]    (+ 1 mark)

             [0        0       1]

 

2.a) Volume = 1/3 (base area) ( height) = 4/3 (+1 mark)

 

2.b) Pyramid: faces = 5, vertices = 5, edges = 8 (+1/4 mark)

       Cube: faces = 6, vertices = 8, edges = 12 (+1/4 mark)

       Relationship = vertices + faces - edges = 2 (+1/2 mark)

 

2.c)

outward-facing unit normal vectors for each face

ABCD: (0,0,-1)

            ABE: (0,-0.707,0.707)

            BEC: (0.707,0,0.707)

            ECD: (0,0.707,0.707)

            AED: (-0.707,0,0.707)

  (-0.5 mark for each mistake)

  (-1 mark if normal vectors were not unit vectors)

  (+2 marks if correct)

 

outward-facing unit normal vectors for each vertex

            A: (-0.65,-0.65,0.38)

            B: (0.65,-0.65,0.38)

            C: (0.65,0.65,0.38)

            D: (-0.65,0.65,0.38)

            E: (0,0,1)

(-0.5 mark for each mistake)

(-1 mark if normal vectors are not unit vectors)

(+2 marks if correct)

(+1 mark if vectors are wrong but the way to calculate them is right)

 

3.

5 cases:

ray: (0,0,0)->(0,0,1), cylinder (0,10,10);(0,-10,10), radius (1). Answer: hit at (0,0,9) (+2 marks)

ray: (0,0,0)->(0,10.6,9.2), cylinder (0,10,10);(0,-10,10), radius (1). Answer: hit at (0,10.7,9.3) (+2 marks)

ray: (0,0,0)->(0,2,1), cylinder (0,10,10);(0,-10,10), radius (1). Answer: no hit (+2 marks)

ray: (0,0,0)->(0,0,1), cylinder (0,5,5);(0,-5,10), radius (1). Answer: hit at (0,0,6.3) (+1 marks)

ray: (0,0,0)->(0,3,1), cylinder (0,5,5);(0,-5,10), radius (1). Answer: no hit (+1 marks)

 

4.

No because the angles between faces may not be preserved after the perspective projection, or yes if the inverse of the perspective transform is applied prior to the test. (+1 mark)

The edges to be drawn do not change with changes in the camera eye position. (+1 mark)

Pros: By eliminating edges early on the pipeline, computational time is saved over the next phases. (+0.5 mark)

Cons: We could save more time by doing the same procedure in the object space, or we may lose computational time with edges that will be culled/clipped in later stages of the pipeline. (+0.5 mark).

 

5.a) If fingers are there -> +2 marks

       If hierarchy is working -> +1 mark

 

5.b) If knuckles are drawn as described -> +2 marks

       If hierarchy is working -> +1mark

 

5.c) Several algorithms were accepted.  Some examples are:

 

Detection of vertices inside cube (for all vertices of both cubes).

Detection of edge-plane intersections (for all edges of both cubes).

Detection of plane-plane intersections.

 

Note: This is supposed to be a general algorithm between 2 cuboids.  If it is specific for the program -> -1 mark.

 

5.d) if top cuboid turns white when there is a collision -> + 3 marks

 

5.e) if wrist is rotating, and the hierarchy is working, in terms of (X,Y,Z)-> +3 marks.