← Image Processing for EveryoneToolsInVisionLearning Center
Intensity Mappings · Lesson 22

Design a Piecewise Brightness Mapping

The archivist wants to brighten shadows without washing out highlights.

Watch the lesson

Design a Piecewise Brightness Mapping explained visually

1:27

The archivist wants to brighten shadows without washing out highlights. English captions are optional and start off. The complete transcript follows the written lesson.

Lesson overview

What you will learn

The archivist wants to brighten shadows without washing out highlights.

  1. A practical question
  2. The useful idea
  3. Work through the example
  4. Limits and next step
01

A practical question

The archivist wants to see detail in a photograph's shadows without washing out the bright sky. One brightness slider moves everything together, so let's try a mapping with different behavior in different ranges. For dark input values, we can make a larger change. For already bright values, we can make a gentler change.

02

The useful idea

Draw a graph with input intensity on one axis and output intensity on the other. Connect a few chosen points with straight segments. The slope of each segment tells us how strongly that part of the range is stretched. If brighter inputs should remain brighter outputs, keep the mapping ordered instead of making it reverse direction.

03

Work through the example

Test the mapping on a quiet shadow and on the brightest important highlight. A steep shadow segment can expose a faint mark, but it can also exaggerate noise. If the top segment pushes many highlights to the same maximum, we lose distinctions in the display copy. We should choose the break points using real examples, then look at the result, not just the graph.

04

Limits and next step

The original scan stays untouched; the mapping is a recorded viewing choice. Next, we'll ask why a stored display value and a physical amount of light are not always proportional.

Worked example

Map dark input values more steeply while keeping the bright interval gentler.

Knowledge check

Quick check: test your understanding

Try it yourself: In the situation described above, explain the method and one reason its output might be misleading.

Check the reasoning

A piecewise mapping uses different input-output slopes across intensity intervals. A steep segment can amplify noise or clip important highlights.

What is the main idea behind design a piecewise brightness mapping?

A piecewise mapping uses different input-output slopes across intensity intervals.

How is it used in the example?

Map dark input values more steeply while keeping the bright interval gentler.

What limitation should be checked?

A steep segment can amplify noise or clip important highlights.

Further reading

Digital Image Processing, 4th edition — Rafael C. Gonzalez and Richard E. Woods.

Original ToolsInVision teaching examples. Editorial approach · Suggest a correction

Accessible referenceLesson 22 transcript203 words · Video transcript · Matches the published narration and captionsOpen transcript

The archivist wants to see detail in a photograph's shadows without washing out the bright sky. One brightness slider moves everything together, so let's try a mapping with different behavior in different ranges. For dark input values, we can make a larger change. For already bright values, we can make a gentler change.

Draw a graph with input intensity on one axis and output intensity on the other. Connect a few chosen points with straight segments. The slope of each segment tells us how strongly that part of the range is stretched. If brighter inputs should remain brighter outputs, keep the mapping ordered instead of making it reverse direction.

Test the mapping on a quiet shadow and on the brightest important highlight. A steep shadow segment can expose a faint mark, but it can also exaggerate noise. If the top segment pushes many highlights to the same maximum, we lose distinctions in the display copy. We should choose the break points using real examples, then look at the result, not just the graph.

The original scan stays untouched; the mapping is a recorded viewing choice. Next, we'll ask why a stored display value and a physical amount of light are not always proportional.