WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
313600
[HDR] Replace ShouldDecodeToHDR with DecodingDestination
https://bugs.webkit.org/show_bug.cgi?id=313600
Summary
[HDR] Replace ShouldDecodeToHDR with DecodingDestination
Said Abou-Hallawa
Reported
2026-04-28 17:30:34 PDT
ShouldDecodeToHDR allows two decoding options for HDRness: No and Yes. For ShouldDecodeToHDR::Yes we set the option { key: kCGImageSourceDecodeRequest, value: kCGImageSourceDecodeToHDR } when calling CGImageSourceCreateImageAtIndex() or CGImageSourceCreateThumbnailAtIndex(). For decoding gain-map images, we need a third option. We need to decode the base image but we need to decode the gain-map image as well. For this purpose the enum ShouldDecodeToHDR will be replaced with another enum called DecodingDestination. The values of DecodingDestination are { Base, GainMap, HDR }. For Base and GainMap, the base image will be decoded, i.e. sending { key: kCGImageSourceDecodeRequest, value: kCGImageSourceDecodeToSDR } to CGImageSource. But for GainMap, the gain-map image will be decoded also. For HDR, { key: kCGImageSourceDecodeRequest, value: kCGImageSourceDecodeToHDR } will be send to CGImageSource. DecodingDestination::GainMap will be chosen only when the image has a gain-map and the context is remote, i.e. the actual display happens in GPUProcess. If the image has a gain-map but the context is local, DecodingDestination::HDR will be chosen. This means the gain-map is applied in WebContent process in this case. ImageFrame will now have three slots for three possible destinations. DecodingOptions will hold DecodingDestination and it will use it to check for matching.
Attachments
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2026-04-28 17:41:11 PDT
<
rdar://problem/175805956
>
Said Abou-Hallawa
Comment 2
2026-05-05 04:11:31 PDT
Pull request:
https://github.com/WebKit/WebKit/pull/64255
EWS
Comment 3
2026-05-08 10:04:36 PDT
Committed
312893@main
(8d2285e7bc8e): <
https://commits.webkit.org/312893@main
> Reviewed commits have been landed. Closing PR #64255 and removing active labels.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug