Wednesday, October 14, 2009

Gamma Correct Lighting, On The Moon!

When I explain gamma correct lighting to people, sometimes they look at images and aren't certain which is supposed to be better.

E.g. in GPU Gems 3, The Importance of Being Linear two spheres are shown, similar to these:

Two spheres lit by a directional light. Which has gamma correct math?


A small thought occurred to me: there's an object people are familiar with that will help them to understand, the moon:
Two spheres lit by a directional light, compared with an image of the moon.
Which has gamma correct math?


Still don't see it.. yes, it's subtle... shall we make it obvious with a gradient?


Yes, it is but one example, there are many more. But it's a good basic visual example.

If you'd like to read more on gamma correct rendering:
[EDIT: See the comments for some nice thoughts from people who've spent more time on this.

Naty points out another good example in Real Time Rendering.]

Thanks to "ComputerHotline" on openphoto.net for the image of the moon.