A Designers Tutorial in using Image Based Illumination and High Dynamic Range Imagery

Report this File

Th_camera_shadows

Views:

71,627

Updated:

Dec 05, 2006

Readership Level:

Advanced

Tags:

Maya Versions:

1.x, 2.x, 3.x, 4.x, 5.x, 6.x, 7.x

Platforms:

linux, mac, windows

Owner:

Language:

English

Step 2: Using the HDR image to generate lights to create lights



At this stage we will be deriving actual Maya lights from the HDRI image through the use of the exported Lightgen file that was created earlier (pp 56).

  • Load Brock's Lightgen Control script
  • This will bring up a panel which allows you to import your lightgen outputted MEL file
        Figure 29


        Brock's Lightgen Control at load up


  • From the File Menu choose Lightgen Script Open and open the MEL file you created in Lightgen.
        Figure 30


        Open the lightgen script


  • After the script is opened you will now be able to control the directional lights created from the script.
        Figure 31


        Brock's Lightgen Control after MEL script loaded in



  • It is also possible to adjust the Light Hue, Saturation, and Value for all the lights.
  • Shadows may be enabled from the Upper, Lower, or all of the Lights in Dmap or Raytrace
  • Once the lights are looking good it is important to break the Intensity so that each light may be tweaked individualy. Without breaking the intensity the values are locked to the dimmer
      • Figure 32


        Locked intensities



  • It is also possible to break all the other connections to the lights so that the shadows may be tweaked individually too.
        Figure 33


        Breaking connections


  • Continue to modify the lights so that they provide good lighting for the model as shown below.

Figure 34


Second step in Maya (left) and the resulting rendered image (right)


Step 3: Creating scene specific elements


For some CG mock-ups there may be "special" lighting situations that need to be created. Examples include caustics and fog. If this step is not required for your CG mock-up, you may skip this step (pp 57).

  • The Brock's Lightgen Control script also allows the input of an additional Lightgen MEL file


      • Figure 35


        Generating additional lights




  • Set the percentage first of what amount of lights to keep then click Generate and browse to the appropriate file.
  • Once the top percentage of the lights have been selected then enable light specific items for those lights
  • Below is an example image of an object that would require special lighting. On the left is the Maya setup and on the right is the image rendered in Maya with just a caustic pass.




Figure 36



Third step in Maya (left) and the resulting rendered image (right)


See a Video of this Step



Advanced Use: Matching a specific angle and creating shadows


In order to make the final result look as convincing as possible there are two additional advanced used stages that can help blend a CG mock-up into the live action photograph.

  • Any camera in Maya can have an image plane attached to it. By mapping in the desired background image into this image plane it is possible to interactively place the camera an image. This is valuable for making sure the camera's angle matches that of the real camera.
Figure 37


A scene in Maya with an the background image plane attached to the camera

  • For shadows you need to create a ground plane that matches the one in the photograph. By renderning in seperate layers we can use the difference of the ground plane with the ground plane with shadows to extract just the shadow information. This can be done easily using the Difference layer in Photoshop.
Figure 38


A scene in Maya with an the background image plane attached to the camera and a ground plane to reveive shadows


By using these advanced steps you are able to create an even more realistic looking composite. Keep in mind at this point the lights have not been manipulated in position or placement at all from the default.


Figure 39

click for larger version
Rendered and composited image with all the stages of this pipeline plus shadows




Step 4: Dirtying up the image

  • At this point you should be able to produce a pretty convincing high quality render. However, the image will still need to be composited into the background and "dirtied up" to make it look convincing. Above is how the image looks with all of the elements combined before dirtying up the image.
  • Launch Photoshop and open your image(s)
  • Blur and Noise work well for dirtying up the image
  • Render out as much as possible in layers so that it can be composited separately
  • Below is an example of this pipeline with the cg mock-up camera composited on top of the background image.
Figure 40
click for larger version

As with any lighting setup there needs to be constant tweaking in order to produce the best results. It should be clear that using just IBI alone is not a very effective solution, but by stepping though this pipeline it is possible to generate an accurate rendered image from using the HDRI file as the base for all of the different lighting stages.


Figure 41

Below are some examples of the camera being lit through different lightprobes (left) that are HDR images in angular format. The lighting is just using the first stage of this pipeline to visualize the different lighting aspects possible



My Related Links:



Thesis Production - a HTML page that describes parts of my thesis work over the past year in more detail (incomplete)

My Created Lightprobes


Other Links:


Brent Watkins - the person responsible for helping me with my scripting difficulties

Paul Debevec's Homepage
- The creator and probably the largest promoter of HDRI

HDRShop - Debevec's free HDR creation program

Debevec SIGGRAPH 2001
- Debevec's Image Based Lighting 2001 SIGGRAPH course

Debevec SIGGRAPH 1997
- Debevec's Recovering Range Radiance Maps from Photographs 1997 SIGGRAPH course

Debevec SIGGRAPH 1998 - Debevec's Reendering Synthetic Objects into Real Scenes 1998 SIGGRAPH course

Simon Bunker - a rendering guru with some excellent work and descriptions of HDRI

CGTechniques.com
- A site with several tutorials regarding HDRI

OpenEXR
- An open source format from ILM that supports HDR information

HDRIE - A free HDR image reader and editor from the University of Illinois

ATI - Rendering with Natural Light in Real Time
- a real time example of Debevec's Rendering with Natural Light

rthdribl DX9 - Real Time High Dynamic Range Image-Based Lighting in Direct X 9


Comments

Write a Comment

You must be logged in and have verified your email address to leave a comment. Login or create an account