Bug 293450
| Summary: | [HDR] Avoid colorSpace transformation and double caching when sharing an image with GPUProcess | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Said Abou-Hallawa <sabouhallawa> |
| Component: | Images | Assignee: | Said Abou-Hallawa <sabouhallawa> |
| Status: | RESOLVED FIXED | ||
| Severity: | Normal | CC: | sabouhallawa, webkit-bug-importer |
| Priority: | P2 | Keywords: | InRadar |
| Version: | WebKit Nightly Build | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
Said Abou-Hallawa
Currently ShareableBitmap shares an image with GPUProcess by drawing it to a SharedMemory only if its colorSpace is not sRGB. Otherwise it uses the data provider to copy the pixels to a SharedMemory. In addition to the SharedMemory, the image metadata which is stored in ShareableBitmapConfiguration, GPUProcess can construct the original image.
Also NativeImage::draw() does the tone-mapping to SDR in WebProcess before sharing the image with GPUProcess. It does this by drawing the image to an SDR unaccelerated ImageBuffer. But this forces RemoteResourceCacheProxy to double cache the image: one copy for the SDR and the other copy for the HDR.
These two steps can be avoided if (1) the data provider approach is used for any colorSpace (2) the system tone-mapping APIs are used to tone-map the HDR image to SDR.
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Radar WebKit Bug Importer
<rdar://problem/151876825>
Said Abou-Hallawa
Pull request: https://github.com/WebKit/WebKit/pull/45787
Said Abou-Hallawa
*** Bug 292679 has been marked as a duplicate of this bug. ***
EWS
Committed 295899@main (1cfbc06323c8): <https://commits.webkit.org/295899@main>
Reviewed commits have been landed. Closing PR #45787 and removing active labels.
Said Abou-Hallawa
*** Bug 288881 has been marked as a duplicate of this bug. ***