1
$\begingroup$

Wikipedia says that:

If a mesh covers more pixels in screen space than it has vertices, interpolating colour values from samples of expensive lighting calculations at vertices is less processor intensive than performing the lighting calculation for each pixel as in Phong shading.

Why does it matter that there are more pixels than there are vertices? In the quote it also says that Gourand shading performs lighting calculation "at vertices" while Phong does it in pixels.

I have always thought that both shading schemes are the same, just that Gourand interpolate colours along vertices, while phong creates a reflection vector to interact with the light sources for specular reflection. Is this correct?

$\endgroup$

1 Answer 1

3
$\begingroup$

I agree that it is a bit superfluous to have the "[i]f a mesh covers more pixels in screen space than it has vertices". Basically, if it doesn't then no interpolation is needed since the color of a pixel can be determined by the vertices it contains. But this is just a degenerate case of interpolation and there isn't much reason to call it out.

Your final paragraph is roughly correct, but it does imply that you need to calculate the Phong reflection model at each pixel using the interpolated normal in the Phong shading case while you don't in the Gouraud shading case. In the latter case, you are linearly interpolating colors calculated using the Phong reflection model at the vertices to produce pixel color values. In the former case, you are linearly interpolating normal vectors calculated at the vertices to produce pixel normals which you then use in the Phong reflection model per pixel.

The Phong reflection model is the "lighting calculation".

$\endgroup$
2
  • $\begingroup$ Is it right to say that for Phong, we compute the colour per pixel but not in the gourand model because the viewing angle varies pixel by pixel, and so the reflection component's colour will vary by pixel as well? $\endgroup$
    – winnie99
    Commented May 24, 2018 at 18:58
  • $\begingroup$ We clearly compute a color per pixel in both cases as the color varies pixel to pixel. What we don't do in Gouraud shading is perform the "lighting calculation", i.e. compute the Phong reflection model, per pixel. The viewing angle is changing regardless, it's just that Gouraud shading doesn't bother to accurately model how that would affect the color. That said, it certainly doesn't behave as if the viewing angle is fixed, otherwise you'd get flat shading. $\endgroup$ Commented May 24, 2018 at 19:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.