The Lightbox
  « make a HDR Image »
News Messageboard Tutorials Chat Old board Links

by Christian Bauer

 

 

 

Please follow this link to read a newer tutorial about creating HDR Images with hdrshop and a fisheye lense.




Here you won't find a what a HDRI is, but how you can make one.

A little warning at the beginning: HDR-Images are not normal RGB- Images, they are build of different exposed photographies and that's why they can get real big. You also have to be very precise during the prozess of making a hdri to get a good result.

 

1. How to photograph

HDR-Images can be used as spherical enviroments but also as normal textures. You need lightwave to use them but the first new renderer are in betastage which will understand that format too.

What do i need?
We want to make a spherical projection with only one viewpoint. For that we need a camera and a precisonspherical mirror. To photograph a sherical mirror have one very important advantage: You have the whole 360°/180° enviroment in only one Image (but you have also the camera on the mirror and a small area behind the sphere with distortions... who cares if you only need it for lighting a scene). For a HDRI we need at least five photos with different exposure time. We also need two statives, one for the camera and one for the spherical mirror.

The best way to photograph is with a digitalcamera, because you can be sure to get pixelprecise results ,while if you are scanning from a photo you also have to rotate the azimuth. Some Digitalcameras don't give you the chance to change the exposure time, but you can change the imagebrightnes and the camera stores the informations about exposuretime internally to your jpg-file. Well, photoshop or in this example ACDSee can read these information.

If you have a digicam where you can sett the exposuretime manualy don't forget the f-stop.

Here are the informations from a jpg, shot by a digicam

Exposure time 0,012..
F-number 4.4

 

The exposuretime have to be converted.

0,012 sec. are 1/77 sec. which is normally used for this Parameter.

So we have a exposuretime of 1/77 sec.

 

 

What have i do with the pictures now?
I have taken someimages (shot freehanded) , i know the exposuretime and now i'm ready for photoshop:

We only have to crop the image:

Every image have to have the same height and width!!! The image have to be cropped along the tangents of the mirror.

nur zur erklärung, ich habe heute nachmitag beschlossen ein tutorial zu machen und hatte aber kein Stativ zuhause .. ;)

 

Your images should look like that now:

1/20 sec. 1/90 sec. 1/500 sec.

If you have written down the exposuretime you are ready for the funny part....

 

 

2. Software

We now have five images which have to be kompiled to a HDR-Image.
For that we need a software from
Paul Debevec .

This Software makes from many singleimages one HDR-Image. There is only one problem with this Software: it needs PPM-Images.

But there is a solution for the problem: when the JPE-Group released their imageformart they also gives away a encoder, and with this encoder also a decoder, which can convert any jpg to a ..yes, ppm. You can download it from here .... This is not my software, so i can't garantee you that this software is ok!!!!

to use the Software more easier i have put it in a RMB-command.

it's only hard for you if you don't understand german ;) ..i'm on a german w2k so i'm not sure if the things have that name i think.... please correct me!

At first we open w-explorere and go to the "Extras" menu, then to the Folderoptions and then to the Filetype-Tab.
You can now see all registered filetypes. Now search for "JPG" ..and exactly jpg!.

Then the bottom should be names "advanced" or so... there you have a dialogbox where you press "new...". In the next dialogbox you can assign a command to the RMB-propertymenu which is similar to a batchfile.

We call the command "convert" and in the next field you have to browse to your djpeg.exe file and append the option "-ppm" and "%1"

"-ppm" converts the jpg to ppm , "%1" is the file whe have pointed at before.

If you now use the RMB over a jpg you can directly convert it to a ppm.. easy, isn't it?

 

There is another port of this software which can read tga's. You can download it from http://dcine.dyndns.org/mkhdr/ and don't have to play with the software below.

Problem solved, so we can go on with Mkhdr.....

 

 

3. setup MkHDR

Mkhdr.exe is a Comandlinetool and need external options and something like a scenedescription. With the scenedescription you let mkhdr know what it should do with the files.

In this Textfile you have a list with your imagenames , exposuretime, f-Stop(?) and two options which are not important for the quality.
The Textfile should look like that:

Wald_1000.ppm 1000 4.4 3 0 --->name of the image, 1000=exposure time(1/1000) ,4.4 = f-Stop, gain, neutral density
Wald_50.ppm 500 4.4 3 0

Wald_10.ppm 250 4.4 3 0
Wald_10.ppm 125 4.4 3 0
Wald_10.ppm 60 4.4 3 0
Wald_10.ppm 30 4.4 3 0

.....and so on

 

next we create a batchfile in the same folder as mkhdr.exe
it should look like that:

mkhdr.exe -w dummy [path\]wald.txt wald.hdr

the parameter "-w dummy" is not required but without the parameter mkhdr crashes on my system......hmm.. ???
followed by the textfile where [path\] is naturally the path to your textfile and then followed by the name of your outputfile.

RUN!

Ready!!!