HDR merging and tone mapping
Combine exposure information or fuse well-exposed regions, then map the result into a displayable range.
Different exposures preserve useful information in different intensity ranges.
Align the bracketed images and account for exposure when required.
Dim and bright regions can draw evidence from different exposures. Clipping cannot be reversed from a single saturated sample.
The drawing illustrates combined visibility. Radiance estimation and exposure fusion have different outputs; tone mapping applies to a radiance result.
Tone-map a radiance result for the target display.
Illustrative example. The stages explain the method; they are not a live OpenCV execution.
Try it on an image
Experiment at pixel level
Fuse two exposure images with Mertens exposure fusion. Without an upload, the second image is a darker exposure of the input. This experiment produces an LDR fusion, not calibrated HDR radiance.
The engine loads on your first run. Your images stay in this browser.
Scroll over either image to zoom at the pointer. Use the scrollbars to pan both views over the same relative area. Zoom is relative to the input; pixel coordinates belong to each image. Warps can change scene correspondence.
Pixel inspector RGBA · native values · matched scale · 9 × 9 output pixels
Select a pixel
Select a pixel
When to use it
Recover a wider scene brightness range from an exposure bracket or create an exposure-fused image.
How it works
- 01Align the bracketed images and account for exposure when required.
- 02Merge radiance estimates or fuse contrast, saturation and exposure quality.
- 03Tone-map a radiance result for the target display.
exposures → radiance or fusion → display mapping
What to tune
Debevec/Robertson use exposure information; Mertens performs exposure fusion. Tone-mapper parameters change appearance, not captured evidence.
Where it breaks down
Moving subjects cause ghosts. Exposure fusion is not the same as calibrated HDR radiance reconstruction.
TypeScript API
Open an entry for its exact overloads, parameter descriptions, result ownership and pinned upstream source.
All of these calls execute on the CPU. Native objects need explicit disposal. See matrices and ownership and build compatibility.
Related methods
Non-local means denoising
Average pixels whose surrounding patches look similar, even when they are not immediate neighbours.
Image inpainting
Fill a masked region by propagating nearby image structure and colour into it.
Seamless cloning
Blend a region by solving for pixel values that fit selected image gradients and boundary conditions.
Panorama stitching
Combine overlapping images through matching, camera estimation, warping and blending.