WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
[patch]
Patch
bug-225280-20210502092348.patch (text/plain), 6.66 KB, created by
Sam Weinig
on 2021-05-02 09:23:48 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Sam Weinig
Created:
2021-05-02 09:23:48 PDT
Size:
6.66 KB
patch
obsolete
>Index: Source/WTF/ChangeLog >=================================================================== >--- Source/WTF/ChangeLog (revision 276882) >+++ Source/WTF/ChangeLog (working copy) >@@ -1,3 +1,16 @@ >+2021-05-02 Sam Weinig <weinig@apple.com> >+ >+ Add support for DestinationColorSpace::DisplayP3 in preparation for DisplayP3 canvas >+ https://bugs.webkit.org/show_bug.cgi?id=225280 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Add new ENABLE_DESTINATION_COLOR_SPACE_DISPLAY_P3 macro to declare which ports >+ support P3 backing stores. Currently, only the Apple/Cocoa ports support it. >+ >+ * wtf/PlatformEnable.h: >+ * wtf/PlatformEnableCocoa.h: >+ > 2021-04-30 Darin Adler <darin@apple.com> > > Use SortedArrayMap in a few more places >Index: Source/WTF/wtf/PlatformEnable.h >=================================================================== >--- Source/WTF/wtf/PlatformEnable.h (revision 276882) >+++ Source/WTF/wtf/PlatformEnable.h (working copy) >@@ -245,6 +245,10 @@ > #define ENABLE_DEVICE_ORIENTATION 0 > #endif > >+#if !defined(ENABLE_DESTINATION_COLOR_SPACE_DISPLAY_P3) >+#define ENABLE_DESTINATION_COLOR_SPACE_DISPLAY_P3 0 >+#endif >+ > #if !defined(ENABLE_DESTINATION_COLOR_SPACE_LINEAR_SRGB) > #define ENABLE_DESTINATION_COLOR_SPACE_LINEAR_SRGB 1 > #endif >@@ -901,6 +905,10 @@ > > #if USE(CG) > >+#if ENABLE(DESTINATION_COLOR_SPACE_DISPLAY_P3) && !HAVE(CORE_GRAPHICS_DISPLAY_P3_COLOR_SPACE) >+#error "ENABLE(DESTINATION_COLOR_SPACE_DISPLAY_P3) requires HAVE(CORE_GRAPHICS_DISPLAY_P3_COLOR_SPACE) on platforms using CoreGraphics" >+#endif >+ > #if ENABLE(DESTINATION_COLOR_SPACE_LINEAR_SRGB) && !HAVE(CORE_GRAPHICS_LINEAR_SRGB_COLOR_SPACE) > #error "ENABLE(DESTINATION_COLOR_SPACE_LINEAR_SRGB) requires HAVE(CORE_GRAPHICS_LINEAR_SRGB_COLOR_SPACE) on platforms using CoreGraphics" > #endif >Index: Source/WTF/wtf/PlatformEnableCocoa.h >=================================================================== >--- Source/WTF/wtf/PlatformEnableCocoa.h (revision 276882) >+++ Source/WTF/wtf/PlatformEnableCocoa.h (working copy) >@@ -671,6 +671,10 @@ > #define ENABLE_APP_BOUND_REQUESTS 1 > #endif > >+#if !defined(ENABLE_DESTINATION_COLOR_SPACE_DISPLAY_P3) >+#define ENABLE_DESTINATION_COLOR_SPACE_DISPLAY_P3 1 >+#endif >+ > #if !defined(ENABLE_DESTINATION_COLOR_SPACE_LINEAR_SRGB) > #define ENABLE_DESTINATION_COLOR_SPACE_LINEAR_SRGB 1 > #endif >Index: Source/WebCore/ChangeLog >=================================================================== >--- Source/WebCore/ChangeLog (revision 276882) >+++ Source/WebCore/ChangeLog (working copy) >@@ -1,3 +1,25 @@ >+2021-05-02 Sam Weinig <weinig@apple.com> >+ >+ Add support for DestinationColorSpace::DisplayP3 in preparation for DisplayP3 canvas >+ https://bugs.webkit.org/show_bug.cgi?id=225280 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Add new ENABLE_DESTINATION_COLOR_SPACE_DISPLAY_P3 macro to declare which ports >+ support P3 backing stores. Currently, only the Apple/Cocoa ports support it. >+ >+ When ENABLE(DESTINATION_COLOR_SPACE_DISPLAY_P3), also define ColorSpaceDestination::DisplayP3. >+ This is not currently used, but will be in subsequent changes. >+ >+ * platform/graphics/ColorConversion.cpp: >+ (WebCore::converColorComponents): >+ * platform/graphics/ColorSpace.cpp: >+ (WebCore::operator<<): >+ * platform/graphics/ColorSpace.h: >+ (WebCore::callWithColorType): >+ * platform/graphics/cg/ColorSpaceCG.h: >+ (WebCore::cachedCGColorSpace): >+ > 2021-05-01 Antti Koivisto <antti@apple.com> > > Share style resolvers between author shadow trees with identical style >Index: Source/WebCore/platform/graphics/ColorConversion.cpp >=================================================================== >--- Source/WebCore/platform/graphics/ColorConversion.cpp (revision 276882) >+++ Source/WebCore/platform/graphics/ColorConversion.cpp (working copy) >@@ -328,6 +328,10 @@ ColorComponents<float, 4> converColorCom > case DestinationColorSpace::LinearSRGB: > return asColorComponents(convertColor<LinearSRGBA<float>>(inputColor)); > #endif >+#if ENABLE(DESTINATION_COLOR_SPACE_DISPLAY_P3) >+ case DestinationColorSpace::DisplayP3: >+ return asColorComponents(convertColor<DisplayP3<float>>(inputColor)); >+#endif > } > > ASSERT_NOT_REACHED(); >Index: Source/WebCore/platform/graphics/ColorSpace.cpp >=================================================================== >--- Source/WebCore/platform/graphics/ColorSpace.cpp (revision 276882) >+++ Source/WebCore/platform/graphics/ColorSpace.cpp (working copy) >@@ -75,6 +75,11 @@ TextStream& operator<<(TextStream& ts, D > ts << "LinearSRGB"; > break; > #endif >+#if ENABLE(DESTINATION_COLOR_SPACE_DISPLAY_P3) >+ case DestinationColorSpace::DisplayP3: >+ ts << "DisplayP3"; >+ break; >+#endif > } > return ts; > } >Index: Source/WebCore/platform/graphics/ColorSpace.h >=================================================================== >--- Source/WebCore/platform/graphics/ColorSpace.h (revision 276882) >+++ Source/WebCore/platform/graphics/ColorSpace.h (working copy) >@@ -52,6 +52,9 @@ enum class DestinationColorSpace : uint8 > #if ENABLE(DESTINATION_COLOR_SPACE_LINEAR_SRGB) > , LinearSRGB > #endif >+#if ENABLE(DESTINATION_COLOR_SPACE_DISPLAY_P3) >+ , DisplayP3 >+#endif > }; > > WEBCORE_EXPORT WTF::TextStream& operator<<(WTF::TextStream&, ColorSpace); >@@ -108,6 +111,10 @@ template<typename T, typename Functor> c > case DestinationColorSpace::LinearSRGB: > return std::invoke(std::forward<Functor>(functor), makeFromComponents<LinearSRGBA<T>>(components)); > #endif >+#if ENABLE(DESTINATION_COLOR_SPACE_DISPLAY_P3) >+ case DestinationColorSpace::DisplayP3: >+ return std::invoke(std::forward<Functor>(functor), makeFromComponents<DisplayP3<T>>(components)); >+#endif > } > > ASSERT_NOT_REACHED(); >@@ -141,6 +148,9 @@ template<> struct EnumTraits<WebCore::De > #if ENABLE(DESTINATION_COLOR_SPACE_LINEAR_SRGB) > , WebCore::DestinationColorSpace::LinearSRGB > #endif >+#if ENABLE(DESTINATION_COLOR_SPACE_DISPLAY_P3) >+ , WebCore::DestinationColorSpace::DisplayP3 >+#endif > >; > }; > >Index: Source/WebCore/platform/graphics/cg/ColorSpaceCG.h >=================================================================== >--- Source/WebCore/platform/graphics/cg/ColorSpaceCG.h (revision 276882) >+++ Source/WebCore/platform/graphics/cg/ColorSpaceCG.h (working copy) >@@ -129,6 +129,10 @@ static inline CGColorSpaceRef cachedCGCo > case DestinationColorSpace::LinearSRGB: > return linearSRGBColorSpaceRef(); > #endif >+#if ENABLE(DESTINATION_COLOR_SPACE_DISPLAY_P3) >+ case DestinationColorSpace::DisplayP3: >+ return displayP3ColorSpaceRef(); >+#endif > } > ASSERT_NOT_REACHED(); > return sRGBColorSpaceRef();
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 225280
: 427528