HDRI The Cheap And Nasty Way

Having tinkered about with producing some HDRI sequences using the excellent light-probes created by Paul Debevec I decided to have a go at producing one myself. What interested me was how "fast and dirty" I could make the techniques whilst still producing acceptable results. To that end I decided to keep equipment and expense to a minimum. Just a camcorder, a tripod and the cheapest light-probe in existence.

Video capture of a light-probe.

This is my light-probe. It is an oversize, plastic Christmas bauble bought from a "Everything for a Pound" shop. You won't get cutting edge computer graphics technology any cheaper. Having shawn it of its tinsel and holly attachments I had a working if imperfect light-probe. As you can see it has seams and scratches but how much would that matter? That's the point of this test.

I thought as a first test it would be best to keep it simple. To this end I decided to shoot a backplate of my dining table with my camcorder and then shoot the probe also with camcorder. Because the depth of field on video cameras is so great I was able to shoot the different exposures by varying the aperture as, obviously, the shutter speed of a video camera is fixed. Once I had shot 6 still images of the probe at different apertures and had shot the backplate, I was then able to capture the footage all off one tape and into my computer. This method has advantages and disadvantages. The most obvious disadvantage is that the resolution of the probe image will only be PAL ie 576 pixels high. It is important to remember that PAL has non-square pixels so you will need to resize your image grabs to 768x576 to make the probe appear round, rather than rugby ball shaped. An advantage of shooting the probe images straight onto video rather than film is that, providing your tripod is steady, the images will automatically register properly once you've imported them into the computer. Once you've done this and converted them to square images, it's time to make the HDR map.

Making the HDR Map

Six exposures, one stop apart.

Using Photoshop I created 6 square images, each representing one extra stop of exposure. I then loaded these into HDRShop, available from Paul Debevec's web site. This is an amazing piece of software which enables you to create HDRI in a range of mapping types (I use latlong because it makes writing the shader easier) and a variety of file types. I outputted floating point Tiffs as these are easily read by BMRT. Now I had the HDR image I needed to create the CG elements to be composited into the scene.

The CG Elements

Simulation scene in Maya.

Here is the Maya scene (you can use any animation software that will output RIBs) in which I have matched the camera angle I shot earlier and made a CG "stand-in" for the table top. On this I have a simple dynamics system involving some metal dominoes and balls The dynamics simulation is outputted to RIBs which then have a sphere added with the latlong layout HDR image mapped onto it using a ReadArchive call. This sequence is rendered, in this case using Entropy.

The Rendered Image

Entropy render of the scene.

Here is a frame from the sequence as it comes straight out of the renderer. The CG "stand-in" table top has been given a colour which is close to the real table. This is so the final difference matted composite will have appropriately coloured shadows.

The Difference Image

Entropy render for difference keying.

The image on the right is a rendering of the table "stand-in" without the dominoes or balls on it. This is required because the final image will be difference matted with this image to produce the alpha for the foreground element.

The Result of Tweaking

Final composite.

After difference matting the foreground render with the difference image and then compositing the result over the backplate shot earlier we have a smoothly integrated image with appropriate shadows, reflections etc. All that is left is a bit of compositing magic to grade the shot, add a little glow and a widescreen crop etc. And that's all there is to it.

This whole process from shooting the backplate to kicking off the render took less than an afternoon. I think the results are of an acceptable quality given the imperfect state of the light-probe, the low resolution of the probe image and the speed with which it was produced. It goes to show that you don't need vastly a expensive digital camera to produce good-looking results although, if you do have access to such kit the results will improve of course.

Creative Commons License
This work is licensed under a Creative Commons Attribution-Noncommercial-No Derivative Works 3.0 Unported License.