


Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!



Problem 1: Rasterization. A particular triangle, when rasterized, produces the following fragments, each with pixel coordinates (xs, ys) and screen-space depth zs.
xs ys zs 13 22 19. 14 22 19. 10 23 18. 11 23 19. 12 23 19. 13 23 19. 10 24 19. 11 24 19. 12 24 19. 10 25 19. 11 25 19. 12 25 19. 11 26 20.
Table 1: The fragments table
What are the (x, y) coordinates and depths of the triangle’s three vertices? Hint : The answer is not unique.
Answer: All answers should satisfy:
(i) All of and only those segments lie in the triangle; (ii) The depths of the coordinates satisfy zi = 19.2 + 0.2(xi − 13) + 0.3(yi − 22) = 0. 2 xi +
One possible solution is (9. 5 , 23 , 18 .8), (14. 5 , 21. 5 , 19 .35) and (10. 5 , 27. 5 , 20 .35).
The MATLAB script posted on the website is for viewing the segments.
Problem 2: Mesh representations. The half-edge table in Table 2 represents a triangle mesh.
Answer: Most simple meshes can be pushed down and drawn on to the plain. In this question, we can also try to draw following triangles on the plane (Fig 1, in which the numbers repre- sent the edges): (0, 8 , 15), (1, 22 , 16), (2, 10 , 9), (3, 17 , 18), (4, 12 , 11), (5, 19 , 20), (6, 14 , 13) and
hedge pair next 0 1 8 1 0 22 2 3 10 3 2 17 4 5 12 5 4 19 6 7 14 7 6 21 8 9 15 9 8 2 10 11 9 11 10 4 12 13 11 13 12 6 14 15 13 15 14 0 16 17 1 17 16 18 18 19 3 19 18 20 20 21 5 21 20 23 22 23 16 23 22 7
Table 2: The half-edge table
(7, 21 , 23). The (0, 8 , 15), for instance, comes from the ring 0 → 8 → 15 → 0 in the table. Note all triangles except the (5, 19 , 20) are counterclockwise, and (5, 19 , 20) is clockwise because it is pointing back to us.
Now pull it up from the plane we can see the mesh is a octohedren (or any other shape with the same topology), as shown in Fig. 2 (the numbers represent the vertices). Table 3 shows one possible way of indexed mesh representation.
Problem 3: Triangle Strips. Given a cube, by dividing each face into two triangles, we could create a mesh with 12 triangles. Figure 3 illustrates one possible way of dividing the faces. We can use 3 triangle strips to represent the mesh: (3, 1 , 4 , 5 , 8 , 6 , 7 , 2 , 3 , 1), (1, 2 , 5 , 6) and (4, 8 , 3 , 7).
By changing how the cube is divided into triangles, you can get away with fewer strips. Find a triangulation and a set of triangle strips that represent the cube with as few strips as possible.
Answer: Figure 4 is a way to divide the faces, and the strip is (6, 1 , 2 , 3 , 6 , 7 , 8 , 3 , 4 , 1 , 8 , 5 , 6 , 1).
Figure 3: Triangle mesh of a cube
Figure 4: Solution to the cube triangle mesh