CAP 202 - Computer Animation II

Lesson 19 - Basic Lighting


This lesson describes the many kinds of lights in 3DS Max and their use. Objectives important to this lesson:

  1. Ambient light
  2. Light types in 3DS Max
  3. Shadows
  4. Three-point lighting
  5. Managing lights

The first topic in the lesson is ambient light. This is light that comes from objects in a scene, not from light sources. It is light that radiated from some light source, hit objects in the scene, and is now bouncing back from those objects (that do not radiate light themselves). It can be thought of as reflected light or indirect light. Think about walls in rooms. Why do we paint the walls of a room a light color when we want to brighten the room? It is because light colors reflect more light than dark colors, adding to the amount of ambient light in a room.

3DS Max does have an ambient light feature, but it does not produce the result we might want. You may have noticed in the underwater lesson that the ambient light in a 3DS Max scene is set to black by default. The problem is that virtual surfaces don't work exactly like real surfaces, so the lesson will show us how to use secondary light sources to produce the effect of ambient light.

Exercise Notes and Questions

Work through the exercises and turn in your answers to all questions below as part of the homework for this assignment.

Exercise 1: Open the the indicated file.
In steps 3 and 4, you see why just increasing the ambient light does not help the scene much. The room fills with the selected amount of light, but it doesn't illuminate the subject or look realistic.
There is already a light (a spotlight) on the left side of the scene. In steps 8 through 9 you turn the light on, and render the perspective view again. This solves the problem.

In photographic terms, you just added a fill light to the scene. It lets you see the side of the subject that was not lit in the beginning. More on this idea in a bit.

The text explains that you will use three categories of lights in 3DS Max, but it dashes our hopes of simplicity by endlessly subdividing the categories. Let's do what we can to simplify it:

  • standard lights - these are like real movie lights, and they come in several types
    • omnidirectional (omni) - think of a small star that shines in all directions; the text compares it to a bare light bulb
    • spotlight - light comes from a point in a cone shape, like the Field of View property of a camera. In this case, the cone is really two cones that can be set with the same dimensions. The cones are called the hotspot and the falloff. The hotspot is the brightest part of the light, the falloff is the outer cone that is larger and dimmer than the hotspot at most focal settings. When the hotspot and the falloff have the same value in 3DS Max, the light is a sharp spot like you see in a theater. When the falloff has a larger value, the light from the spot has two regions, and a more gradual change between them. To see the effect in real life, get a MagLite (or other focusing flashlight) and change the focus in a dark room.
      Spots come in two sub-types:
      • target - like a target camera, a target spot can be linked to an object in the scene
      • free - free spots can and must be pointed manually at the objects you want them to light
    • direct -the text describes the light from a direct light as coming through a cylinder instead of a cone; the light does not spread out like the cone of a spotlight
  • photometric lights - complex lights that can represent real-world lighting
  • systems - simulated sunlight, with lots of parameters to set

Set color hereMore terminology about light is offered. Light in a scene can vary in color as well as in intensity. As you add more lights to a scene, you will want to consider both qualities. Mixing colors can be artistic, or it can be a case of less (fewer colors) being more (better output). Adding lights to a scene adds to the total light level. You may want to adjust the level of each light so that the total light in the scene is not more than you want or need. It is not immediately clear how to change the color of a light. Set the color by clicking the unlabeled panel next to the Multiplier field on the Intensity/Color/Attenuation rollout.

A word most people have not heard is attenuation, which means fading over distance. In the real world, the farther light travels, the more it fades in intensity. It follows what is called the inverse square law in physics. Think about standing two feet from a lamp. Its light has a certain intensity, or brightness. Now walk four feet from the lamp. The light must travel twice as far to you. Its intensity will be 1 over the increase in distance (2, because you doubled the distance) squared. 1/2*2 = 1/4. The light will be one quarter as bright when twice as far away.

In 3DS Max, we can control attenuation. We can set where it begins and ends, we can set an attenuation (decay) rate, or we can turn it off. All of which looks unrealistic, but may help fake realism in a scene where we do not notice the light sources. (Inverse square is one of the decay rate choices.)

Shadows are discussed and demonstrated in the next exercise. The text presents the idea that shadows add to the realism of a scene, and we should study placing them to best effect. Two types of shadow generation are discussed:

  • shadow maps - a bitmap is dynamically generated for shadows each time the render engine runs; this method is fast, but does not understand transparent objects
  • ray-traced shadows - this type of shadow casting understands transparent objects, and creates sharp edged shadows, but is slower than a shadow map method

Other methods are mentioned, but no details are offered.

Exercise 2: The text suggests we reset the program before continuing. We are using more render functions now, so it is a good idea.
Open the shadows.max file as instructed. Step 3 gives us a hot key to render a scene: F9.

In steps 5 through 7 you create a light. I could not select a Target Spot until I switched the Lights dropdown from photometric to standard.

Step 8
tells you that by default, a spotlight does not cast shadows. In my copy of 3DS Max 2009, it does.

In steps 10 and 11, we learn new terms.
Question 1: What is the other term for the hotspot property of a spotlight?
Question 2: What is the other term for the falloff property of a spotlight?

In step 13 you turn on the shadows. You render again and see the problem with a shadow map: glass does not cast the same kind of shadow as pewter, but shadow map thinks it does,
This problem is corrected with the slower, but superior ray-traced shadow method.

The text turns to lighting techniques. It tells us that there are many techniques, but it only describes one classic: three-point lighting. Three kinds of lights are used in this method:

  • key light - the main light for your scene
  • fill light - a lift that fills in shadows that would make the scene too dark
  • back light- a light that fills the background of the scene to give it depth and separation from the foreground

This is a classic approach, but some people prefer other techniques that more closely simulate nature. This article on light offers an opposing point of view and other suggestions.

Exercise 3: This exercise shows you what can happen using a three-point lighting technique.
The exercise is a bit vague about the placement of the lights in this exercise. The parameters are defined well, but you may notice that your results do not look like the author's results. Mine certainly didn't.

As a matter of fairness, I will suggest that when you finish step 29, you should render the scene, then save it with a new name. Then you can open the 3-point Final.max file and see the author's render. Before you feel bad about it, notice two things: that render looks a lot like the final version in step 29, and the lights in the scene look only a little like the ones we were told to make.

One more short topic: the Light Lister is a tool for managing the lights in your scene. Exercise 4 shows you some settings you can check and change on it.

rose statueExercise 4: Open the indicated file. Open the Tools menu (third item on the menu bar) and select Light Lister.
The Light Lister gives you quick access to key features for lights. Note that it actually tells you what to click to change the color of a light. Follow the instructions in the exercise to see the effect of turning some options on and off. Try putting some pink funeral lights on the statue and toggling shadows on and off. The rendered version changes with each choice.