---
title: "Phong shading method"
subject: "Computer Graphics"
chapter: 8
key: "semester_5/computer_graphics:phong-shading-method"
source: https://www.bctengineer.com/q/semester_5/computer_graphics/phong-shading-method
site: BCT Engineering
---

# Phong shading method

Computer Graphics · Chapter 8: Illumination and Surface Rendering methods

- Asked in: 2073 Shrawan, 7 marks; 2070 Asar, 6 marks; 2076 Asoj, 8 marks; 2078 Bhadra, 6 marks; 2076 Chaitra, 6 marks; 2067 Mangsir (old course), 7 marks; 2074 Chaitra, 8 marks; 2071 Shrawan, 6 marks; 2081 Chaitra (new course), 1 marks (asked 9 times)
- Video: [Polygon Rendering   Constant shading , Gouraud Shading , Phong Shading](https://www.youtube.com/watch?v=VrPHSuy5BWM) — Ekeeda
- Answer checked by Claude Opus 5.5 (high effort) on 2026-10-14
- Page: https://www.bctengineer.com/q/semester_5/computer_graphics/phong-shading-method
- Whole chapter: https://www.bctengineer.com/md/semester_5/computer_graphics/chapter-8

## Question

Explain the Phong shading (normal-vector interpolation) method for polygon rendering, with the steps and the necessary mathematical expressions.

## Short answer

Phong shading interpolates surface normals across the polygon and applies the illumination model at each pixel. Vertex normals are averaged from adjacent faces; normals are interpolated linearly along edges and scanlines, then normalized. Intensity I = ka·Ia + IL[kd(N·L)+ks(N·H)^n] is computed per pixel, producing realistic highlights but at higher computational cost.

## Answer

**Phong shading** (normal-vector interpolation) is a polygon-rendering method that interpolates the **surface normal** across the polygon and applies the illumination model at every pixel. It gives accurate highlights and removes most Mach bands.

**Steps**
1. Find the normal at each polygon vertex by averaging the unit normals of the polygons sharing that vertex:

   N_v = (Σ N_k) / |Σ N_k|

2. Interpolate the normal along the polygon edges. For an edge from vertex 1 to vertex 2, at scan line y_s:

   N = ((y_s − y2)/(y1 − y2)) · N1 + ((y1 − y_s)/(y1 − y2)) · N2

3. Interpolate along the scan line between the left (a) and right (b) edge intersections, for pixel x_p:

   N = ((x_b − x_p)/(x_b − x_a)) · N_a + ((x_p − x_a)/(x_b − x_a)) · N_b

   (Incremental form: N' = N + ΔN.)
4. Normalise N at each pixel (and the pixel position gives L, V).
5. Apply the illumination model at each pixel:

   I = ka·Ia + IL [ kd (N·L) + ks (N·H)^n ]

   where L = light direction, H = (L + V)/|L + V| and n = specular exponent.

```text
 N1 o--------------o N2     edge interpolation of normals
     \   Na ---- Nb  /      scan-line interpolation
      \  (pixel N)  /       -> intensity at each pixel
```

Features: realistic highlights and smooth results, but slow because the illumination equation is evaluated for every pixel. (Fast Phong shading uses incremental calculation to reduce the cost.)

## Check yourself

The answer's key points as multiple-choice questions, with the correct option and why.

1. What does Phong shading interpolate across a polygon?
   A. Surface normal vectors
   B. Vertex intensities
   C. Colour only
   D. Depth values
   Answer: A. It is also called normal-vector interpolation. (Key point: What is interpolated)

2. How is the normal at a vertex found?
   A. Take the largest polygon's normal
   B. Average the unit normals of polygons sharing it and normalise
   C. Use the first polygon's normal
   D. Add depth values
   Answer: B. N_v = sum(N_k)/|sum(N_k)|. (Key point: Vertex normal)

3. What must be done at each pixel?
   A. Use only the vertex intensity
   B. Copy the neighbouring pixel
   C. Normalise the interpolated normal and apply the illumination model
   D. Skip lighting
   Answer: C. The illumination model is evaluated at every pixel. (Key point: Per pixel step)

4. What is the main drawback of Phong shading?
   A. Misses highlights
   B. Strong Mach bands
   C. Cannot handle meshes
   D. Slow, as lighting is calculated for every pixel
   Answer: D. Accuracy comes at higher cost than Gouraud. (Key point: Trade-off)

## Related in Computer Graphics

- [Gouraud shading for polygon rendering](https://www.bctengineer.com/question.md?key=semester_5%2Fcomputer_graphics%3Agouraud-shading-intensity-interpolation) — Computer Graphics, chapter 8, asked 6×
- [Compare Gouraud and Phong shading](https://www.bctengineer.com/question.md?key=semester_5%2Fcomputer_graphics%3Acompare-gouraud-phong) — Computer Graphics, chapter 8, asked 7×
- [Fast Phong shading](https://www.bctengineer.com/question.md?key=semester_5%2Fcomputer_graphics%3Afast-phong-shading) — Computer Graphics, chapter 8, asked 2×
- [Phong shading and Mach-band effect](https://www.bctengineer.com/question.md?key=semester_5%2Fcomputer_graphics%3Aphong-mach-band-effect) — Computer Graphics, chapter 8
- [Spatial orientation / normal of a polygon](https://www.bctengineer.com/question.md?key=semester_5%2Fcomputer_graphics%3Aspatial-orientation-polygon-calculation) — Computer Graphics, chapter 6, asked 5×
- [Polygon table and normal of S1](https://www.bctengineer.com/question.md?key=semester_5%2Fcomputer_graphics%3Apolygon-table-surface-normal-s1) — Computer Graphics, chapter 6
