RGBE image format
|Internet media type||
|Magic number||23 3f 52 41 44 49 41 4e 43 45 0a|
|Type of format||lossless image format|
RGBE is an image format invented by Gregory Ward Larson. It stores pixels as one byte each for RGB (red, green, and blue) values with a one byte shared exponent. Thus it stores four bytes per pixel.
RGBE allows pixels to have the dynamic range and precision of floating point values in a relatively compact data structure (32bits per pixel) - often when images are generated from light simulations, the range of per-pixel color intensity values are much greater than will nicely fit into the standard 0..255 (8-bit) range of standard 24-bit image formats. As a result, the bright pixels are either clipped to 255 or end up losing all their precision in dimmer pixels.
By using a shared exponent, the RGBE format gains some of the advantages of floating point values whilst using less than the 32 or 16 bytes per pixel that would be needed for single precision or half precision data in the IEEE floating-point format; and with a higher dynamic range than half precision.
A second variant of the format uses the XYZ color model with a shared exponent. The mime type and file extension is identical, thus applications reading this file format need to interpret the embedded information on the color model.
Greg Ward provides code to handle RGBE files in his Radiance rendering system.