How are RAW files tone-mapped for camera and Lightroom previews?
Asked 5/15/2019
7 views
2 answers
0
RAW sensor data contains more tonal information than a monitor can display directly. When I view a RAW image in-camera or in Lightroom, what am I actually seeing? Is the extra dynamic range already compressed or tone-mapped for the preview? Also, when I adjust shadows or highlights in Lightroom, how is it able to recover detail that isn't obvious in the preview? Finally, are halo artifacts in RAW edits related to tone mapping?
Originally by Photography Stack Exchange contributor. Source · Licensed CC BY-SA 4.0
Photography Stack Exchange contributor
7y ago
2 Answers
5
This question is probably too broad for the format here and might be closed as such. But it becomes a little unwieldy to place links to even a few of the many existing questions/answers we have here that touch on the various questions you raise in comments. This isn't really so much a complete answer as it is an attempt to point you in a direction where these subjects have already been addressed here.
Is tone mapping automatically applied to RAW images?
A lot of processing is applied to the raw image data collected by the camera's sensor and digitized by the camera's processor before there is what we consider a "viewable image." This processing include what you refer to as "tone mapping."
What do I actually see when I look at the preview from my Camera or LR? Where is the extra range? is it clipped? or already tone mapped?
For more about what a raw file is and what a raw file isn't (Hint: the image you see on your camera's LCD screen or on your computer is not an unprocessed raw image), please see:
RAW files store 3 colors per pixel, or only one?
What does an unprocessed RAW file look like?
Is the Preview file always the photo taken by the camera?
If I save as RAW+JPG, which of the two is shown on the screen of a Canon 600D?
Why are my RAW images already in colour if debayering is not done yet?
What happens when I slide the shadows slider up or the highlights down? what is LR doing to "bring back the highlights"?
What you are looking at on your screen is only one of countless possible interpretations of the raw image data. This preview is based on the instructions that have been given to Lightroom as to how the raw image data should be interpreted. When you move a slider, you change the set of instructions with regard to whatever the slider you moved controls. Lightroom then either:
- Estimates the effect this change would have on reprocessing the raw data with the modified instruction set and renders this change on your screen
or
- Reprocesses the raw image data with the new instruction set and displays the result on your screen.
Which one LR does is determined by your user settings regarding "quality" and "speed' in the 'User preferences' section covering rendering of the preview you see on your screen when working with raw files. In either case, when you actually tell LR to export the file, it will use the instruction set you have designated to go back and reprocess the raw image data to produce a jpeg, png, tiff, etc. for export.
For more about what happens when you move a slider while processing a raw image file in Lightroom or other raw processing applications, please see:
Camera dynamic range and Lightroom exposure slide
Why can software correct white balance more accurately for RAW files than it can with JPEGs?
Are the occasional Halos on RAW caused by the tone mapping?
In short: Yes, halos can be a result of global tone-mapping, whether done via an "HDR" application or by aggressively tone-mapping a single raw file.
Regarding how global tone-mapping can lead to halos in boundary areas between very light and very dark areas, please see:
What is the difference between Digital Blending & HDR technique
Originally by user15871. Source · Licensed CC BY-SA 4.0
user15871
7y ago
0
Generated from our catalog & community — verify before relying on it.
Yes. A RAW file is not directly viewable, so some processing is always applied before you see a preview. That includes mapping the sensor’s captured values into a displayable image, often including gamma correction and tonal compression.
So the preview on your camera or in Lightroom is already a rendered interpretation of the RAW data, not the untouched sensor data itself. The extra dynamic range is not simply “shown as-is”; it is compressed into the smaller range your screen can display.
When you move the Shadows or Highlights sliders, Lightroom is remapping the underlying RAW tonal values before display. Because the RAW contains more recorded levels than an 8-bit display or JPEG can show, the software can redistribute tones to reveal detail in bright or dark regions with smoother results than an already-rendered JPEG.
This is why highlight/shadow recovery works: the data was often present in the RAW even if the initial preview did not emphasize it.
Halos are not an inherent property of RAW files themselves. They are more typically artifacts of aggressive local contrast, sharpening, HDR/tone-mapping style processing, or similar rendering choices.
Recommended products
UniqueBot
AI7y ago
Your Answer
Related Questions
Can Lightroom HDR Merge change how strongly it compresses dynamic range?
What does the first preview screen in Luminance HDR show before tone mapping?
What are the advantages of RAW beyond higher bit depth?
How can I avoid haloing and white sky around a subject when making HDR from a single RAW file?
Can HDR software create a true HDR image from a single RAW file automatically?
