In this lesson, you take a daylight image of a desert landscape, adjust its output to resemble nighttime lighting conditions, then incorporate the result into the scene as a background. You’ll add a Glare effect to enhance the appearance of the lights, then introduce a few more photometric lights to illuminate the interior of one barracks.

Set up the lesson:

  • Continue working on your own scene file or in the lighting_and_renderingarmy_compound folder, open army_compound_lighting_no_bkrnd.max.

Sep 24, 2019  The Material Texture Loader is a 3ds Max script designed to quickly load in textures, create a material and apply that to your scene. It works well for a PBR texture workflow, but it can be used for any type of texture that needs to be loaded as part of a material.

Add a background image:

3ds Max Materials

  1. Open the Rendering menu and choose Environment to open the Environment And Effects dialog. On the Common Parameters rollout, click the Environment Map button (at present, the text on the button says (“None”).

    3ds Max opens the Material/Map Browser.

  2. On the Material/Map Browser, double-click the Bitmap map type. (Bitmap is in the Maps Standard group.)

    3ds Max opens a file dialog.

  3. In the file dialog, navigate to the sceneassetsimages folder, click desert.jpg to highlight it, then click Open.

    The image is a desert landscape, taken during the day.

  4. On the Exposure Control rollout make sure Process Background And Environment Maps is off.

    When this option is turned on, 3ds Max applies the exposure control to the background map itself. For most bitmaps (those that don’t save a high dynamic range), in effect this makes the background and other environment maps invisible.

  5. Make sure no object is selected, right-click a viewport, and from the quad menu, choose Hide Unselected.
  6. Render the Camera01 viewport.

    With all objects hidden, 3ds Max has rendered only the background image. It is apparent that you will need to make the image darker so it suits the nighttime scene.

    Leave the Environment And Effects dialog open for now.

Adjust the background image:

  1. Open the Slate Material Editor.
  2. In the Material/Map Browser panel on the left, navigate to the Sample Slots group.
  3. Drag the Environment Map button from the Environment And Effects dialog and drop it onto an unused sample slot. The sample slot shows a red bar across it when you are able to drop the map.

    3ds Max asks if this should be an instance or a copy. Make sure Instance is selected, and then click OK.

  4. Close the Environment And Effects dialog.
  5. Drag the sample slot with the environment map into the active View.

    Once again, 3ds Max asks if this should be an instance or a copy. Make sure Instance is selected, and then click OK.

  6. In the active View, double-click the Bitmap node so you can see its parameters in the Parameter Editor panel to the right.
  7. On the Output rollout, decrease the Output Amount to 0.033.
  8. Render the Camera01 viewport again.

    The result is a heavily underexposed image, resembling a night sky: a digital version of filming “day for night.”

    Background bitmap heavily underexposed to suit night scene

  9. Right-click the Camera01 viewport, select Unhide All from the quad menu, then render the scene again.

    The background adds depth and interest to the scene.

  10. Close the Slate Material Editor.

Add a Glare effect:

mental ray provides a number of special effects designed to give light objects added realism. Here, you will add a Glare effect to the army compound lights, to simulate their interaction with dust particles and ambient humidity.

  1. Click (Render Setup). On the Render Setup dialog, go to the Renderer tab. In the Camera Effects rollout Camera Shaders group, turn on the Output shader toggle.

    As the shader button shows, mental ray provides a Glare shader as a default shader for camera output, but by default this shader is turned off, so you have to enable it “by hand.”

  2. Open the Slate Material Editor, and move it so you can see both dialogs.
  3. In the Material/Map Browser panel on the left, navigate to the Sample Slots group.
  4. Drag the Camera Shaders Output button from the Render Setup dialog and drop it onto an unused sample slot. The sample slot shows a red bar across it when you are able to drop the map.

    3ds Max asks if this should be an instance or a copy. Make sure Instance is selected, and then click OK.

  5. Close the Render Setup dialog.
  6. Drag the sample slot with the Glare shader into the active View.

    Once again, 3ds Max asks if this should be an instance or a copy. Make sure Instance is selected, and then click OK.

  7. In the active View, double-click the Glare node so you can see its parameters in the Parameter Editor panel to the right.
  8. On the Glare Parameters rollout, change the value of Spread from 2.0 to 0.5.
  9. Close the Slate Material Editor.
  10. Make a clone of the existing rendered frame, then render the scene.

    Rendered scene with Glare effect added to light sources

    Compare the two images to see the Glare effect. This effect is most pronounced on the suspended lamp over the jeep.

  11. Close the Rendered Frame Windows.
Adding Material Slots 3ds Max

Add lights to the interior of the barracks on the right:

  1. Activate the Top viewport, then zoom and pan until the far-right barracks comes into view.
  2. On the Create panel, click (Lights). On the Object Type rollout, click Free Light to turn it on.
  3. Place the new light by clicking the apex of the barracks roof, near the entrance.
  4. Activate the Front viewport, zoom to see the front of the right-hand barracks, then use (Select And Move) to raise the light object on its Y axis until it is above the floor but below the roof, as shown in the illustration.

    The interior barracks lights are fluorescent, so the new light object should be suspended about two feet (about 0.6m) from the ceiling.

  5. Go to the Modify panel. On the Templates rollout, open the drop-down list and choose 4ft Pendant Fluorescent (Web).

    Now you will set the color the light will cast.

  6. On the Intensity/Color/Attenuation rollout, make sure the preset Light radio button is chosen (as opposed to color temperature: “Kelvin”), then choose Fluorescent (White) from the Light drop-down list.

    The scene calls for a standard fluorescent fixture consisting of four tubes. Rather than physically re-creating each tube, you can simply bump up the intensity of the single light object by a factor of four.

  7. In the Intensity/Color/Attenuation rollout Dimming group, change the value of Resulting Intensity to 400% (percent).
  8. In the Top viewport, make two instances of the fluorescent light. Distribute them evenly along the length of the barracks.
  9. On the Shadows rollout, turn shadows On so the ceiling lights will cast shadows.
  10. Activate the Camera01 viewport and render the scene again.

    Rendered scene with interior lights added to the barracks on the right

    The inside of the right-hand barracks is now illuminated, with light spilling out of the entrance.

Save your work:

  • Save the scene as my_army_compound_nighttime_completed.max.
Add more material slots 3ds max

Summary

3ds Max Material Editor

In this tutorial, you learned how to use photometric lights to illuminate a night scene. You specified the color of the light source and defined how shadows were cast. You also learned how to take a background image, adjust its output, and apply it as a background to the night scene. Finally, you saw how a mental ray Glare shader can be applied to a light object to improve the realism of the rendering.

3ds Max Materials Missing