We are here with you hands in hands to facilitate your learning & don't appreciate the idea of copying or replicating solutions. Read More>>

www.vustudents.ning.com

 www.bit.ly/vucodes + Link For Assignments, GDBs & Online Quizzes Solution www.bit.ly/papersvu + Link For Past Papers, Solved MCQs, Short Notes & More

Dear Students! Share your Assignments / GDBs / Quizzes files as you receive in your LMS, So it can be discussed/solved timely. Add Discussion

# CS 602 Computer Graphics Assignment No 3 Solution & Discussion Due Date:12-06-2012

Q No. 1

Q  No. 2

Discuss the “the H test” (highlight detection) in reference of Gouraud          and  Phong shading?                                                                              10

+ How to Join Subject Study Groups & Get Helping Material?

+ How to become Top Reputation, Angels, Intellectual, Featured Members & Moderators?

+ VU Students Reserves The Right to Delete Your Profile, If?

Views: 303

.

+ http://bit.ly/vucodes (Link for Assignments, GDBs & Online Quizzes Solution)

+ http://bit.ly/papersvu (Link for Past Papers, Solved MCQs, Short Notes & More)

### Replies to This Discussion

Gouraud shading gives a much better image than faceted shading (the facets no longer visible). It is not too computationally expensive: one floating point addition (for each color) for each pixel. (the mapping to actual display registers requires a floating point multiplication)

It eliminates creases that you may want to preserve, e.g. in a cube. We can modify data structure to prevent this by storing each physical vertex 3 times, i.e. a different logical vertex for each polygon

by asma

heeeeee see this

solution for second question

Generally, an object will have relatively few highlighted polygons, so it would be computationally more efficient to Phong shade the highlighted polygons, and to Gouraud shade the remainder. In practice, however, the diffuse components produced for a particular pixel by the two interpolation methods differ slightly, and it is necessary to Gouraud shade the entire object. The Phong specular term is then evaluated on the highlighted polygons, and combined with the Gouraud diffuse value.

To enable the implementation of the combined shading algorithm, a test has to be determined to ascertain which of the polygons are partially or fully within an area of specular light. This test is known as the highlight test or H test.

The highlight detection is based on a hierarchy of simple tests that predict the value of the highlight function on the line between two vertices. For there to be a contribution from the specular term N.H (vector H is the halfway vector) we can say:

N.H ≥ T

where T is a threshold term. The value of this term is examined at pair of vertices to predict the variation in its magnitude along the edge. A hierarchy of five simple tests performs this prediction:

## Latest Activity

16 minutes ago
Muhammad Irfan joined + M.Tariq Malik's group

### CS506 Web Design and Development

30 minutes ago
Muhammad Irfan joined + M.Tariq Malik's group

### CS510 Software Requirements and Specifications

30 minutes ago
30 minutes ago
Muhammad Irfan and Areeha Chuhdary joined + M.Tariq Malik's group

### STA301 Statistics and Probability

31 minutes ago
Muhammad Irfan joined + M.Tariq Malik's group

### MGT502 Organizational Behavior

36 minutes ago
44 minutes ago
50 minutes ago
Fari Malik liked Zain Kazimi's discussion Self Poetry Dedicated to Nasir Kazimi
58 minutes ago
1 hour ago
+ ! ! ! ! ! ! Sm!Le and ♦_"Tooba"_♦ are now friends
1 hour ago

1