2079 11

CSC214 ยท 2079 ยท 5 marks

Define the term 'rendering' in computer graphics. Explain Phong Shading Method with its advantage and disadvantage.

Define the term 'rendering' in computer graphics. Explain Phong Shading Method with its advantage and disadvantage. [5]

Computer GraphicsChapter 8: Illumination Models and Surface Rendering TechniquesPolygon Rendering Methods

Quick answer

Rendering is the process of generating a final 2D image from a 3D scene description by applying lighting, shading, color, and other visual effects to the geometric objects in the scene. It transforms a mathematical model of a scene into a realistic or stylized visual output.

Rendering in Computer Graphics and Phong Shading Method


Definition of Rendering (1 mark)

As stated in the notes:

"Scene description + Illumination Model + Rendering Technique = Image"

In other words, polygon (surface) rendering is the process of calculating intensity and color considerations for polygon surfaces so that objects appear realistic on screen.


Phong Shading Method (3 marks)

Phong Shading (also called Normal-Vector Interpolation Shading) is an advanced surface rendering technique that produces smooth and realistic shading across polygon surfaces.

Concept

Instead of interpolating intensity values (as in Gouraud shading), Phong Shading interpolates the surface normal vectors across each polygon surface. The illumination model is then applied at every individual pixel using the interpolated normal, producing a much more accurate and realistic result.

Algorithm / Steps

  1. Calculate the surface normal vector at each vertex of the polygon using the surrounding surface geometry.

  2. Interpolate the normal vectors across the entire polygon surface (both along edges and across scan lines) to obtain a normal vector at every interior pixel.

  3. Apply the illumination model (e.g., Phong illumination model with ambient, diffuse, and specular components) at each pixel using its interpolated normal vector.

  4. Assign the computed intensity to each pixel on the surface.

Diagram (Conceptual)

Vertex N1          Vertex N2
   *-----------------*
    \   Interpolated  \
     \   Normals at    \
      \  each pixel    \
       *-----------------*
     Vertex N3

At every pixel inside the polygon, a normal is interpolated and lighting is computed individually.


Advantages of Phong Shading (0.5 mark)

  • Produces highly realistic images with accurate specular highlights.
  • Eliminates the Mach band effect (intensity discontinuities visible in flat shading).
  • Handles specular reflections much better than Gouraud shading because lighting is computed per pixel.
  • Gives smooth shading across polygon surfaces.

Disadvantages of Phong Shading (0.5 mark)

  • Computationally expensive because the illumination model must be applied at every pixel rather than just at vertices.
  • Slower rendering compared to flat shading and Gouraud shading.
  • Requires more memory and processing power, making it less suitable for real-time applications (historically).

Summary Table

FeatureFlat ShadingPhong Shading
InterpolationNoneNormal vectors
RealismLowHigh
ComputationLeastMost
Specular HighlightsPoorAccurate

Conclusion: Phong Shading is one of the most realistic polygon rendering methods because it computes lighting at every pixel using interpolated normals, at the cost of higher computational requirements.

Short on time? The 1, 5 and 10 mark versions of this answer, flashcards and practice sets come with a program pass.