How To: Automate HDR on Linux (Coming Soon)

The purpose of this article is mainly to server as an outline to myself for the series or posts I need to write to document my current method for automating HDR post-processing. I’m also just trying to get the feel for writing posts and what not. As I write the interesting bits I’ll update this post to link to them. Each documented step will contain links to any software needed. Off the top of my head I know that you’ll need pfstools , pfsCalibration, PFStmo, openexr, qpfstmo, qtpfsgui, and optionally cinepaint.

Oklahoma Memorial Stadium

The basic outline of the process goes like this.

  1. Transfer photos from the camera or media to a hard drive. (This needs to be done all at once so that the next step will go faster.)
  2. Separate each set of 5 exposures into directories so that they are easier to work with. This is made easier by use of a shell script. Part 1 of the series.
  3. Combine each set of 5 exposures into hdr format. Ideally you have already generated a camera response curve so that the processing goes faster. (I’ll have to dig up a link for this.) I’m also generating and saving a scaled down version of the hdr image to make it faster to process preview images at different tone mapping settings. Part 2 (and 2.5?) of the series.
  4. Generate a series of previews using a range of different tone mapping settings. There’s no silver bullet in terms of tone mapping settings to get the best out of every shot. You really have to spend some time playing around with things to get the best look. I will admit that I’m partial to the fattal tone mapping operator (which I think is used by Photomatix (which seems to be the main non-Linux hdr tool)(man, that’s two posts in a row with nexted parentheses….)) Anyway, I currently generate 3 different previews with mild, medium, and extreme amounts of “the hdr effect.” The purpose here isn’t to automate the creation of your final masterpiece, it’s just to give you a quick way to determine which shots will turn out looking good and what settings you might want to start with on them. It’s still up to you to make it look good. (See next step.) Part 3 of the series.
  5. Optionally, fire up cinepaint. I got started on hdr by using cinepaint to combine the exposures to hdr. I’ve found that sometimes I get quite different results from cinepaint than I do from the pfstools merging process. In general if the scene has people or other items moving around in it that would cause a ghosting effect I tend to prefer the cinepaint combination method. It seems to do a more natural looking job of the ghosting. I know it’s strange to talk about anything looking natural in an hdr shot (especially with ghosting), but I can’t think of a better word right now. Maybe “less digital” is a better phrase to describe it. Anyway, once you’ve created your hdr you can go back to step 4 for some previews or go straight to the next step and start tone mapping. (I’ll find a link for this.)
  6. Based on the previews decide which of the hdr sets you want to work with and then fire up qpfstmo and/or qtpfsgui to really get things dialed in. From here it’s all up to you to decide what you think looks good. I’ve found that for some reason I get different results with the two different programs listed above. I think it has to do with the fact that qtpfsgui has a gamma slider on the input side as well as the output side. Part 4 of the series.

Cloud Gate - Chicago

Bonus Steps:

  1. Set up some old machines to get in on the action and act as a sort of hdr rendering farm.
  2. Adapt the automation process to allow the creation of full panoramas. Ideally we want to generate several tone mapped images of each camera position and then be able to generate several panoramas at different tone mapping levels.

Leave a Reply