The Webkit team details the extended support for Safari 15.2 wide color gamut
For most of us, the release of Safari 15.2 as part of iOS 15.2 and macOS 12.1 came and went with little fanfare. Apparently, this was a standard maintenance release with bug fixes and security improvements. But a blog post from the WebKit team describes a new feature that will have a big impact on web viewing.
As Cameron McCormack explains, sites using Safari 15.2 can now choose between two color spaces to create canvas contexts (essentially anything other than images and text): the standard sRGB and the wide color P3. Apple users will recognize the P3 color space that has been used in Mac and iPhone screens since 2015, but so far neither Chrome nor Safari has taken full advantage of it for anything other than images. Safari 15.2 changes this with support for creating 2D canvas contexts using Apple’s Display P3 color space, which will bring richer colors to page elements.
The change will not be immediate. On the one hand, Safari’s default space will always be sRGB, explains McCormack, “to avoid the performance overhead of color space conversions with existing content.” On the other hand, developers will have to request the P3 space for each canvas element, which will take a bit of work.
McCormack says Safari is the first browser to support drawing shapes, text, gradients, and shadows with wide-gamut CSS colors on Display P3 canvases. And despite the difference in intensity between sRGB and Display P3, most designers won’t bother embracing the new space until at least Chrome adds support.
Michael Simon has covered Apple since the iPod was iWalk. His obsession with technology dates back to his first PC, the IBM Thinkpad with the pop-up keyboard to replace the reader. He’s still waiting for it to come back in style.