http://www.hxa.name/tonemapper/
ARTIFEX (ατ) HXA7241 (dοτ) ORG
2005-11-26
Copyright (c) 2005, Harrison Ainsworth / HXA7241.
Develop a premium tone-mapper component available as source code, library and executable.
Implement Ward Larson's 1997 paper:
‘A Visibility Matching Tone Reproduction Operator for High Dynamic Range Scenes’
Ward Larson, Rushmeier, Piatko;
IEEE TVCG 1997.http://radsite.lbl.gov/radiance/papers/lbnl39882/tonemap.pdf
Tone mapping is a necessary stage of rendering, but it is usually an afterthought. A good component could fill a gap in the open-source rendering world. It can be well-separated and made reusable without architectural ramifications. It is quite small and simple, so do-able in a month or two.
Aims:
Requirements are simple: there is only one use case, and a few supplementary features. The use case follows basic command-line tool form: read a file, process it, output a file. But this is augmented with an options file containing switches and metadata.
(actor - user, or renderer)
The primary division separates the user-interface application from the library. In the library the tonemapping specific algorithm is separated from more general graphics and utilities parts. In the application the image file formatting is separated.
reuse (and extend a little):
The main tonemap package classes fall into three groups: some specialised images, some image operators, and one overall workflow-context.
image file format support:
PerceptualMap
Foveal : ImageRgbFloat
Veil : ImageRgbFloat
ToneAdjustment
AcuityFilter
ColorAdjustment
ImageRgbFloat
ImageRgbInt
ColorSpace
A simple, basic form eases portability, and the usage is simple, so: a command-line program is best. This can be a thin wrapper to control a dynamic-link/shared library. Maybe the image format readers could be externalised as plugins.
Just straightforward, portable C++.
Not decided yet... Something precise and numerical is desirable. There are some source and result images, using the same algorithm, at: http://www.anyhere.com/gward/hdrenc/pages/originals.html , and some calibrated images at: http://www.mpi-inf.mpg.de/resources/hdr/gallery.html
input original image
make image of foveal values
human viewer
make image of veil, from foveal image
mix veil into foveal
mix veil into original
adjust original image for color sensitivity
filter original image for acuity
make histogram, from foveal image
adjust histogram
map original image with histogram
output final image
command file:
(luminance is cd/m^2, remember?)
other pixel formats for library interface
accelerate
flare feature
— the more localised eye scattering effects — Cornell paper in Siggraph 1995
white/color shift feature
— simulating the human perception that white looks white even when
illumination is colored.
— research needed
‘A Visibility Matching Tone Reproduction Operator for High Dynamic Range
Scenes’
Ward Larson, Rushmeier, Piatko;
IEEE TVCG 1997.
http://radsite.lbl.gov/radiance/papers/lbnl39882/tonemap.pdf
‘A Model of Visual Adaptation for Realistic Image Synthesis’
Ferwerda, Pattanaik, Shirley, Greenberg;
Siggraph 1996.
http://www.graphics.cornell.edu/pubs/1996/FPSG96.pdf
‘Physically-based Glare Effects for Digital Images’
Spencer, Shirley, Zimmerman, Greenberg;
Siggraph 1995.
http://www.graphics.cornell.edu/pubs/1995/SSZG95.pdf
‘Illumination And Color In Computer Generated Imagery’
Hall;
Springer 1989.
0-387-96774-5.
OpenEXR high dynamic range image format
http://www.openexr.com/
Radiance PIC/RGBE image format
http://radsite.lbl.gov/radiance/refer/filefmts.pdf
PNG image format
http://www.libpng.org/
PPM image format
http://netpbm.sourceforge.net/doc/ppm.html
sRGB color space
http://www.w3.org/Graphics/Color/sRGB
1.65
9
1.75