Shader Glow Effects

To create a glowing effect, it is sometimes better to place a glow on a geometry's shader instead of the light itself. Because a light must be seen in the shot and pointed at the camera to see any light glow and flare, a shader glow is sometimes more desirable. This process will composite a glow on the object assigned the glow shader to simulate a volumetric light such as a street lamp on a foggy night. Shader glows have far less render cost than true volumetric lights.

Try This To light a still-life scene, follow these steps:

1. Open the stm_life_v03.mb file in the Lighting project on the CD. Create a Spot light, place it over the still life, and aim it directly down onto the fruit. Turn on Use Shadows Maya Tips and Techniques" href="/tips-techniques/producing-quality-depth-map-shadows.html">Depth Map Shadows for the light, and set Resolution to 1024. Set Penumbra Angle to 10 and Intensity to 1.5. Press 7 for Lighted mode in the camera1 View panel to see how the light is being cast.

  1. The Spot light will provide the practical light in the scene. You will place a bare bulb on a wire directly above the fruit. Create a NURBS sphere and position it right over the fruit but in the frame for camera1 to see. In the Render Stats section of the Attribute Editor for the sphere, turn off Casts Shadows.
  2. Create a long, thin cylinder for the lightbulb's wire, and position it as if the bulb were hanging from it, as shown here. Turn off Casts Shadows for it as well.
  3. Create a black Phong E shader to assign to the cylinder.
  4. Create a Phong shader for the bulb and assign it to the NURBS sphere. Set its Color to a pale, light yellow, and make it about 50 percent transparent.
  5. Select the Spot light and set its Color to the same yellow. You can do this easily through the Color Chooser. With the shader for the bulb selected, open the Color Chooser by clicking the pale yellow color you just made. Click the right arrow to place the yellow color in the swatches to the right of the main color swatch, or right-click any of the swatches.
  6. Pick the Spot light, and click its Color attribute to set the Color Chooser to that color. Simply click the yellow swatch you created to get the same color on the light. For detail's sake, make the light's color less saturated. Click Accept to close the Color Chooser window.
  7. To make the shader glow for the bulb, open the Hypershade and select the bulb's Phong material. In the Attribute Editor, in the Special Effects section, drag the Glow Intensity slider from 0 to 1.0. If you render the frame, you'll see the glow not quite enough to make it a convincing lightbulb yet. In the Hypershade, select the shaderGlow1 node. This node controls all the glows in the scene.
  8. Set Quality to 0.1. In the Glow Attributes section, set Glow Intensity to 6.0, set Glow Spread to 0.5, and set Glow Radial Noise to 0.2.

The scene file stm_life_v04.mb on the CD contains the full scene for your reference. See Figure 10.41 for the final result.

Figure 10.41 The bare light bulb over the still life is created with a shader glow.

Opengl Light Bulb Example

Figure 10.41 The bare light bulb over the still life is created with a shader glow.

Figure 10.42 Lighting the Red Rocket to match this practical lighting

+1 0

Average user rating: 5 stars out of 1 votes

Post a comment

  • Receive news updates via email from this site