Awesome Gain Maps
September 4, 2026 · View on GitHub
Links, papers, discussion threads, example images and libraries related to HDR using gain mapped JPEGs. This repository started as a collection of links and papers about color HDR. Then after CIC32 it accumulated applications and images from a parallel 30 day challenge on gain maps. Now it's a combination of these threads, a work in progress and a range of samples including photography, video games, visualization and test targets.
| More Examples | Cats | Websites |
|---|---|---|
![]() | ![]() | ![]() |
![]() | ![]() | ![]() |
![]() | ![]() | ![]() |
There is also a multi-page Streamlit app (that includes an HDR color picker) available for in-person demonstration. A SDR (ie non-gain mapped) screenshot jpg of this application is below. For comparison, a gain mapped version of this astronomy image is here :
The resulting gain mapped JPGs have been validated using a MacBook Pro M3 (Sonoma 14.6.1) display and the Brave Browser (1.76.73). The Streamlit dark mode is used for the demo app and a comparable viewing condition may be preferred when viewing the example gain mapped jpegs.
- HDR Image Transcoder - by Yuuichu
- "Convert HDR images between modern HDR still-image formats."
- SMPTE STANDARD : Dynamic Metadata for Color Volume Transform — Application #5
- "Computing and compositing systems must often render multiple sources of content, including text, images, and videos, that can be both standard dynamic range and high dynamic range, on the same display, at the same time."
- Turning the Luminance Up to 11 (wide gamut profile vs gain map) posted to This Endless Frame
- "The appearance of the overhead lighting reflected off the top of the knobs really pops."
- Post on Gain Maps by David Pettersson
- "LinkedIn re-encodes everything you post and discards the metadata gain maps live in. What survives is the ICC profile, which means: PQ-encore the pixels, embed a Rec.2020 PQ profile and let the color management do its work."
- HDR Gain Map Analyzer : A concise tool that decodes HDR Gain Map images and ISO 21496-1 metadata from dual-layer HDR JPEGs. Supports single-channel and three-channel gain maps. Pure-Python — no ExifTool required.
- by daoyuli
- r/Lightroom : I got tired of my HDR edits dying after export, so I built a free/open-source Mac app to fix it
- HDRify : Read/write HDR, EXR and UltraHDR JPGs (Gain maps), includes tone mapping and color space support.
- Online tool by bhouston
- repo includes /assets with examples
- HDR Flashbang : Make an image extremely bright - by Riley Walz
- HDR Image Generation via Gain Map Decomposed Diffusion : (ICCV 2025)
- Convert HDR files to Gain Map HDR : A tool to convert HDR file to Adaptive HDR (Gain Map HDR) and ISO HDR format in HEIC
- HDR2gainmap : RAW photo development to HDR with gain maps, tuned for accurate rendering in Apple Photos
- HLG to SDR/HDR : macOS app for camera HLG HEIF stills (Sony
.HIF, Nikon Z). Folds them to SDR with a choice of operator including BT.2446 Method A, or writes JPG / HEIC carrying an ISO 21496-1 gain map. Installs a Photos editing extension, so the conversion runs on the HLG master rather than on an already folded export. Free.- by dmitry907
- repo page includes side by side comparisons measured against the original HLG file
- Gain-MLP: Improving HDR Gain Map Encoding via a Lightweight MLP
- T. Canham, S. Tedla, M.J. Murdoch, M.S. Brown - March 2025
- "The proposed MLP network architecture. Given the SDR image’s pixel coordinates and RGB values, the network encodes each pixel in a 120-element sine embedding, which is then passed to a two-layer MLP, whose weights are optimized to predict the corresponding gain or gamma map values at each pixel."
- ISO HDR Images Test Sets (22028-5, 21496-1)
- These free images test sets are licensed under the CC BY-NC 4.0 license.
- 1 - ISO_22028-5_HDR_PQ_4.93 : contains 24 ISO TS 22028-5 PQ images, with up to 4.93x headroom
- 2 - ISO_21496-1_Adaptive_HDR_4.93 : contains 24 Adaptive HDR images, with up to 4.93x headroom
- 3 - ISO_22028-5_HDR_PQ_Metadata : contains 23 ISO TS 22028-5 PQ images, with no headroom constraints, and with appropriate metadata
- 4 - ISO_21496-1_Adaptive_HDR : contains 23 Adaptive HDR images, with no headroom constraints
- How to work with HEIC image file types in Python
- pillow-heif : Python library for working with HEIF images and plugin for Pillow.
- ISO/TS 22028-5:2023(en) : Photography and graphic technology — Extended colour encodings for digital image storage, manipulation and interchange — Part 5: High dynamic range and wide colour gamut encoding for still images (HDR/WCG)
- Proposal: gain maps for PNG #380
- ICC HDR Stills Expert Day : 2024
- DCI-P3 : DCI-P3 is a color space defined in 2005 as part of the Digital Cinema Initiative, for use in theatrical digital motion picture distribution[1] (DCDM[2]). Display P3 is a variant developed by Apple Inc. for wide-gamut displays.
- Other Awesome lists
- Paper List | High Dynamic Range Imaging : lists many papers and recent models
- Awesome-Deep-HDR : A collection of deep learning based methods for HDR image synthesis
- ICtCp color space : Dolby
- ICtCp : a color representation format specified in the Rec. ITU-R BT.2100 standard that is used as a part of the color image pipeline in video and digital photography systems for high dynamic range (HDR) and wide color gamut (WCG) imagery.[1] It was developed by Dolby Laboratories[2] from the IPT color space by Ebner and Fairchild.
- ICtCp - Dolby Whitepaper
- Rec. 2020
- Rec. 2100
- CIC 2018 Paper : Assessing Color Discernibility in HDR Imaging using Adaptation Hulls
- SMPTE 2017 Conference : Hitting the Mark - A New Color Difference Metric for HDR and WCG Imagery
- Coding-independent code points : a way to signal the properties of a video or audio stream.[1][2] It can describe the color profile of videos (and still images) in a simpler way than the use of ICC profiles.[3]
- EI 2023 Plenary 2: Embedded Gain Maps for Adaptive Display of High Dynamic Range Images
- More papers
- Advanced High Dynamic Range Imaging by Francesco Banterle, Alessandro Artusi, Kurt DeBattista (2021)
- HDR_Toolbox : HDR Toolbox for processing High Dynamic Range (HDR) images into MATLAB and Octave
- GNU Octave : The Octave syntax is largely compatible with Matlab. The Octave interpreter can be run in GUI mode, as a console, or invoked as part of a shell script.
- Francesco Banterle : Home Page and on github
- PICCANTE : High Dynamic Range (HDR) Library
- Dolby Vision to HDR10, SDR, and HLG Video Converter
- HDRutils : Some utility functions to generate HDR images from a sequence of exposure time or gain modulated images
- HDR 10
- HDR10, is an open high-dynamic-range video (HDR) standard announced in 2015
- HDR 10+
- Ultra HDR Image Format v1.1
- SkJpegGainmapEncoder.cpp
- ISO 21496-1 gainmap support
- SkAndroidCodec: Add gainmap image decoding support
- google/libultrahdr
- imagecodecs library for image format decode / encode, including libultrahdr (1.3.0)
- Playing around with Ultra HDR and ths code, also uses ffmpeg
- I know PNG can handle and contain HD colors, but can it contain HDR colors?
- rawpy : an easy-to-use Python wrapper for the LibRaw library.
- AppleJPEGGainMap : Generating JPG + Gain Map HDR Photos Compatible with iPhones/Macs Photos
- Gain Maps by Eric Chan at Adobe
- Gain Map : Adobe
- Mac Demo App and corresponding documentation
- Gain Map Sample Photos
- JPEG-XL
- ACES
- Applying Apple HDR effect to your photos : You can decode and apply Apple’s HDR gain map to your own images.
- Gain Map - discussion thread
- High Dynamic Range color grading and display in Frostbite : slides
- The high dynamic range imaging pipeline: Tone-mapping, distribution, and single-exposure reconstruction, by Gabriel Eilertsen (2018)
- ColorAide : A library to aid in using colors . . . about ICtCp
- Greg Benz Photography : HDR JPG Gain Map Gallery
- Use Brave browser to view JPEGs with gain maps
- gainmap-js : A Javascript (TypeScript) Encoder/Decoder Implementation of Adobe's Gain Map Technology for storing HDR Images using an SDR Image + a "Gain map"
- How to convert JPG images to AVIF with Python
- darktable : an open source photography workflow application and raw developer.
- Extensible Metadata Platform - XMP : save specific sequence of image edits
- OpenEXR : Test Images
- NEF Format : Nikon Electronic Format (NEF)
- pixls.us : Play Raw category . . . such as
- CR2 : Canon Raw v2 (CR2) . . . Canon 5D camera
- ISET/isetcam . . . (notes w Octave?)
- A most unusual brightness : "The illustrations for Digital Divinity make use of this effect in a brilliant (literally) way by masking a pure white, HDR video such that parts of the illustration glow with an ethereal brightness."
- Inverse Tone Mapping - Upscaling SDR Content to HDR
- Welcome to the wide-gamut test page
- dtinth/superwhite
- "display a very bright white color on HDR-enabled displays with ~1 KB of video file"
- it really is quite bright
- Perceptually uniform color space for image signals including high dynamic range and wide gamut
- Visualizing Errors in Rendered High Dynamic Range Images
- HDR Merge : "Get increased dynamic range in your photos by merging your bracketed RAW files directly within Capture One. The result is a linear DNG that behaves like a RAW file for further editing."
- Color Grading & Finishing : How to - Add a LUT in Avid Media Composer
- Exposure Fusion – local tonemapping for real-time rendering
- HDR NITS ARE A LIE: IT’S TIME TO EMBRACE THE STOP
- Adventures in EDR, Part 1: Displaying EDR Photos in iOS 17 and Adventures in EDR, Part 2: Metal
- How Could I extract MPF images (HDR gain Map) from iPhone's jpegs?
- brew install exiftool
exiftool -b -MPImage2 image_w_gain_map.jpg > gain_map.jpg- Using ExifTool to modify metadata
- OpenCV : High Dynamic Range Imaging : tonemapped and with exposure fusion
- Reading/writing JPEG MPF (Multi-Picture Format) files
- High Dynamic Range Imaging - Exposure sequence & Exposure fusion - EXPOSURE FUSION
- Manual creation of UltraHDR images : discussion thread
- Day-to-Night Image Synthesis for Training Nighttime Neural ISPs : CVPR'22 Oral
- HEIC Image Processing Tools - heic-shenanigans
- Computationally Efficient HDR Video Using a Packed Video Gain Map : Technical Disclosure Commons (2024)
- Use HDR for dynamic image experiences in your app : Apple Developers Video, WWDC 2024
- Gamma Maps: Non-linear Gain Maps for HDR Reconstruction
- Improving-Color-Space-Conversion-for-Camera-Captured-Images-via-Wide-Gamut-Metadata
- Monochrome vs Color Gain Map Examples : from the website of Eric Chan
- American Science & Surplus is fighting for its life. Here’s why you should care. - neat place, nice gain mapped photos
- The iPhone 15 Pro's Depth Maps : and the gain maps
- Apple/Adobe の Gain Map HDR について調べて軽く実装をしてみた
- Process Apple Gain Map: The ImageIO & the Core Image approaches
- Adventures in EDR, Part 1: Displaying EDR Photos in iOS 17 : "Video of the Photos app showing a photo of a sunset, with the sun getting brighter as EDR kicks in."
- vincenttsang/HDR-Gain-Map-Convert : 基于SwiftUI编写的PQ_HDR_to_Gain_Map_HDR转换工具的HDR图片转换器GUI界面
- A Subjective Comparison of Three Standard Tone Mapping Algorithms for HDR-to-SDR Conversion
- Learning Gain Map for Inverse Tone Mapping - ICLR2025
Procedurally generated gain mapped jpeg : motivated by #genuary








