A method of performing bilateral filtering and using the method for
displaying high-dynamic-range images is presented. The method reduces the
contrast of the image while preserving detail of the image. The presently
disclosed method incorporates a two-scale decomposition of the image into
a base layer encoding large-scale variations, and a detail layer. The
base layer has its contrast reduced, thereby preserving detail. The base
layer is obtained using an edge-preserving bilateral filter. The
bilateral filter is a non-linear filter, where the weight of each pixel
is computed using a Gaussian in the spatial domain multiplied by an
influence function in the intensity domain that decreases the weight of
pixels with large intensity differences. The bilateral filtering is
accelerated by using a piecewise-linear approximation in the intensity
domain and appropriate subsampling.