[Radiance-general] Obtaining proper luminance values in scene image generated using HDR sky-probe luminance data

Christian Humann chris at coolshadow.com
Sat Nov 24 16:09:08 PST 2012


Hi Kyle,

Another option is to multiply the first three values in the fourth line of:

hdr_probe_image glow light_probe
0
0
4 1 1 1 0

by the inverse of the exposure eg. (1 / 5.953331e-03 ).

Chris

On Nov 23, 2012, at 6:18 PM, Mehlika Inanici <inanici at u.washington.edu> wrote:

> 
> 
> Kyle,
> 
> You can set the exposure to 1 (pfilt)  to prevent the problems you are experiencing with the probe.
> 
> 
> Mehlika
> 
> On Fri, 23 Nov 2012, Kyle Konis wrote:
> 
>> Dear list,
>> 
>> I am exploring image-based lighting in Radiance and have encountered
>> several issues with the luminance values in the scene images i am
>> generating. I am starting with a hemispherical fisheye image of the
>> sky which must be cropped to a square format via pcompos.
>> 
>> This process leads to a header which puts the EXPOSURE=5.953331e-03 in
>> a location which creates a problem in that the pixel values, as viewed
>> in Photosphere or when rendered via rpict to a test image (looking up
>> from the origin at the sky), are much lower than the original HDR
>> image.
>> 
>> #?RADIANCE
>> CAPDATE= 2012:10:21 17:05:24
>> GMT= 2012:10:22 00:05:24
>> 20111019_cloudy/201110191248.hdr:
>>      CAMERA= Canon Canon PowerShot A570 IS version v.0
>>      EXPOSURE=5.953331e-03
>>      VIEW= -vtv -vh 52.456387 -vv 40.558973
>>      CAPDATE= 2011:10:19 12:48:08
>>      hdrgen created HDR image from 'IMG_0685.JPG' 'IMG_0684.JPG'
>> 'IMG_0683.JPG' 'IMG_0682.JPG' 'IMG_0681.JPG'
>>      PRIMARIES= 0.6400 0.3300 0.3000 0.6000 0.1500 0.0600 0.3127 0.3290
>> pcompos -x 1280 -y 1280 20111019_cloudy/201110191248.hdr -340 -100
>> pfilt -1 -x 600 -y 600
>> pflip -v -c
>> pflip -h -c
>> FORMAT=32-bit_rle_rgbe
>> protate -r -c
>> 
>> -Y 600 +X 600
>> 
>> 
>> In other words, when the EXPOSURE=5.953331e-03 line is in its
>> original position, e.g.:
>> 
>> 
>> #?RADIANCE
>> CAMERA= Canon Canon PowerShot A570 IS version v.0
>> EXPOSURE=5.953331e-03
>> VIEW= -vtv -vh 52.456387 -vv 40.558973
>> CAPDATE= 2011:10:19 12:48:08
>> hdrgen created HDR image from 'IMG_0685.JPG' 'IMG_0684.JPG'
>> 'IMG_0683.JPG' 'IMG_0682.JPG' 'IMG_0681.JPG'
>> PRIMARIES= 0.6400 0.3300 0.3000 0.6000 0.1500 0.0600 0.3127 0.3290
>> FORMAT=32-bit_rle_rgbe
>> 
>> -Y 1536 +X 2048
>> 
>> ...... all is well, and the image displays the correct luminance
>> values for the sky in Photosphere.  Because i need to crop this image
>> to a square format to use it as a light probe, i cannot confirm that a
>> test image (again, looking up from the origin) would render with the
>> proper luminance values, but my guess is that it would.
>> 
>> 
>> I am using the following text to describe an image-based lighting
>> environment consisting of a hemispherical fish-eye image of the sky.
>> 
>> # Image-Based Lighting Environment
>> void colorpict hdr_probe_image
>> 7 red green blue sky_image/HDR_sky_temp.hdr angmap_sky.cal u v
>> 0
>> 0
>> 
>> # specify a "glow" material that will use this image
>> hdr_probe_image glow light_probe
>> 0
>> 0
>> 4 1 1 1 0
>> 
>> light_probe source ibl_environment
>> 0
>> 0
>> 4 0 0 1 180
>> 
>> 
>> 
>> I have tried a number of scripts to manipulate the header text to
>> return the EXPOSURE=5.953331e-03 line to a location where it is again
>> utilized.  In this example (below), which just sticks the line up at
>> the top, Photosphere reads the image and scales the pixels by the
>> exposure value. However, when a scene is rendered using the image as a
>> light probe, the test image again has very low sky luminance values.
>> 
>> 
>> #?RADIANCE
>> EXPOSURE=5.953331e-03
>> #?RADIANCE
>> CAPDATE= 2012:10:21 17:05:24
>> GMT= 2012:10:22 00:05:24
>> 20111019_cloudy/201110191248.hdr:
>>      CAMERA= Canon Canon PowerShot A570 IS version v.0
>>      EXPOSURE=5.953331e-03
>>      VIEW= -vtv -vh 52.456387 -vv 40.558973
>>      CAPDATE= 2011:10:19 12:48:08
>>      hdrgen created HDR image from 'IMG_0685.JPG' 'IMG_0684.JPG'
>> 'IMG_0683.JPG' 'IMG_0682.JPG' 'IMG_0681.JPG'
>>      PRIMARIES= 0.6400 0.3300 0.3000 0.6000 0.1500 0.0600 0.3127 0.3290
>> pcompos -x 1280 -y 1280 20111019_cloudy/201110191248.hdr -340 -100
>> pfilt -1 -x 600 -y 600
>> pflip -v -c
>> pflip -h -c
>> FORMAT=32-bit_rle_rgbe
>> protate -r -c
>> 
>> -Y 600 +X 600
>> 
>> 
>> My questions to the list, ultimately are:
>> 
>> 1) Does the colorpict pattern type, or image-based lighting process in
>> general, have any relationship to the EXPOSURE value of the HDR image?
>> If not, i suppose the solution is to scale all the pixel values in
>> the image and forget about where the EXPOSURE line is in the header.
>> 
>> 2) If the EXPOSURE line in the header is relevant, can anyone
>> recommend a scripting technique to cook up the proper header text and
>> then attach the binary image data from the manipulated (e.g. pcompos,
>> pflip, pfilt) HDR images? For example, i have used "getinfo" to grab
>> the header from the original image and "grep" to grab the EXPOSURE
>> line, i write these to a new file (with #?RADIANCE) as the first line.
>> I then cat the manipulated image file to this new file. This results
>> in an inelegant header for the new file, works in Photosphere, but, as
>> mentioned above, does not lead to a proper sky luminance results when
>> used to generate scene images in radiance.
>> 
>> Any suggestions would be appreciated!
>> 
>> 
>> -Kyle
>> 
>> _______________________________________________
>> Radiance-general mailing list
>> Radiance-general at radiance-online.org
>> http://www.radiance-online.org/mailman/listinfo/radiance-general
>> 
> 
> 
> _______________________________________________
> Radiance-general mailing list
> Radiance-general at radiance-online.org
> http://www.radiance-online.org/mailman/listinfo/radiance-general




More information about the Radiance-general mailing list