Skip to content

[Materials] Upstream support for glass materials#46587

Merged
webkit-commit-queue merged 1 commit intoWebKit:mainfrom
pxlcoder:eng/294306
Jun 11, 2025
Merged

[Materials] Upstream support for glass materials#46587
webkit-commit-queue merged 1 commit intoWebKit:mainfrom
pxlcoder:eng/294306

Conversation

@pxlcoder
Copy link
Copy Markdown
Member

@pxlcoder pxlcoder commented Jun 11, 2025

66fc5e1

[Materials] Upstream support for glass materials
https://bugs.webkit.org/show_bug.cgi?id=294306
rdar://153029937

Reviewed by Abrar Rahman Protyasha and Richard Robinson.

Upstream support for the use of `-apple-visual-effect` with glass materials.

Renaming and refactoring to come in follow-up patches.

* Source/WTF/wtf/PlatformHave.h:

`HAVE_MATERIAL_EFFECT` is unused. `HAVE_MATERIAL_HOSTING` is not. Merge the two.

* Source/WebCore/css/CSSPrimitiveValueMappings.h:
(WebCore::toCSSValueID):
(WebCore::fromCSSValueID):
* Source/WebCore/css/CSSValueKeywords.in:
* Source/WebCore/css/parser/CSSPropertyParserConsumer+AppleVisualEffect.cpp:
(WebCore::CSSPropertyParserHelpers::isKeywordValidForAppleVisualEffect):
* Source/WebKit/Configurations/WebKit.xcconfig:
* Source/WebKit/DerivedSources-input.xcfilelist:
* Source/WebKit/DerivedSources-output.xcfilelist:
* Source/WebKit/DerivedSources.make:
* Source/WebKit/Platform/cocoa/WKMaterialHostingSupport.swift:
(MaterialHostingView.resolvedMaterialEffect(for:)):
* Source/WebKit/WebKit.xcodeproj/project.pbxproj:
* Tools/TestWebKitAPI/Tests/WebKitCocoa/AppleVisualEffectTests.mm:
(TestWebKitAPI::TEST(AppleVisualEffect, GlassMaterialParsing)):
(TestWebKitAPI::TEST(AppleVisualEffect, GlassMaterialParsingWithoutUseSystemAppearance)):
(TestWebKitAPI::TEST(AppleVisualEffect, MediaControlsGlassMaterialParsing)):
(TestWebKitAPI::TEST(AppleVisualEffect, MediaControlsGlassMaterialParsingWithoutUseSystemAppearance)):
(TestWebKitAPI::TEST(AppleVisualEffect, MediaControlsSubduedGlassMaterialParsing)):
(TestWebKitAPI::TEST(AppleVisualEffect, MediaControlsSubduedGlassMaterialParsingWithoutUseSystemAppearance)):
(TestWebKitAPI::TEST(AppleVisualEffect, SubduedGlassMaterialParsing)):
(TestWebKitAPI::TEST(AppleVisualEffect, SubduedGlassMaterialParsingWithoutUseSystemAppearance)):
(TestWebKitAPI::TEST(AppleVisualEffect, NoCrashWhenRemovingLayers)):

Canonical link: https://commits.webkit.org/296094@main

ede99dc

Misc iOS, visionOS, tvOS & watchOS macOS Linux Windows
✅ 🧪 style ✅ 🛠 ios ✅ 🛠 mac ✅ 🛠 wpe ✅ 🛠 win
✅ 🧪 bindings ✅ 🛠 ios-sim ✅ 🛠 mac-AS-debug ✅ 🧪 wpe-wk2 ⏳ 🧪 win-tests
✅ 🧪 webkitperl ⏳ 🧪 ios-wk2 ✅ 🧪 api-mac ✅ 🧪 api-wpe
loading 🧪 webkitpy ⏳ 🧪 ios-wk2-wpt ✅ 🧪 mac-wk1 ✅ 🛠 wpe-cairo
✅ 🛠 🧪 jsc ✅ 🧪 api-ios ✅ 🧪 mac-wk2 ✅ 🛠 gtk
✅ 🛠 🧪 jsc-arm64 ✅ 🛠 vision ✅ 🧪 mac-AS-debug-wk2 ✅ 🧪 gtk-wk2
loading 🧪 services ✅ 🛠 vision-sim ✅ 🧪 mac-wk2-stress ✅ 🧪 api-gtk
✅ 🧪 vision-wk2 ✅ 🧪 mac-intel-wk2 ✅ 🛠 playstation
✅ 🛠 🧪 unsafe-merge ✅ 🛠 tv ❌ 🛠 mac-safer-cpp ✅ 🛠 jsc-armv7
✅ 🛠 tv-sim ✅ 🧪 jsc-armv7-tests
✅ 🛠 watch
✅ 🛠 watch-sim

@pxlcoder pxlcoder self-assigned this Jun 11, 2025
@pxlcoder pxlcoder added the New Bugs Unclassified bugs are placed in this component until the correct component can be determined. label Jun 11, 2025
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is fine for upstreaming, but at some point this should be refactored to be more idiomatic (like omitting the Material.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Noted. Will do when I rename the cases.

@pxlcoder pxlcoder added the unsafe-merge-queue Applied to send a pull request to merge-queue, but skip building and testing label Jun 11, 2025
https://bugs.webkit.org/show_bug.cgi?id=294306
rdar://153029937

Reviewed by Abrar Rahman Protyasha and Richard Robinson.

Upstream support for the use of `-apple-visual-effect` with glass materials.

Renaming and refactoring to come in follow-up patches.

* Source/WTF/wtf/PlatformHave.h:

`HAVE_MATERIAL_EFFECT` is unused. `HAVE_MATERIAL_HOSTING` is not. Merge the two.

* Source/WebCore/css/CSSPrimitiveValueMappings.h:
(WebCore::toCSSValueID):
(WebCore::fromCSSValueID):
* Source/WebCore/css/CSSValueKeywords.in:
* Source/WebCore/css/parser/CSSPropertyParserConsumer+AppleVisualEffect.cpp:
(WebCore::CSSPropertyParserHelpers::isKeywordValidForAppleVisualEffect):
* Source/WebKit/Configurations/WebKit.xcconfig:
* Source/WebKit/DerivedSources-input.xcfilelist:
* Source/WebKit/DerivedSources-output.xcfilelist:
* Source/WebKit/DerivedSources.make:
* Source/WebKit/Platform/cocoa/WKMaterialHostingSupport.swift:
(MaterialHostingView.resolvedMaterialEffect(for:)):
* Source/WebKit/WebKit.xcodeproj/project.pbxproj:
* Tools/TestWebKitAPI/Tests/WebKitCocoa/AppleVisualEffectTests.mm:
(TestWebKitAPI::TEST(AppleVisualEffect, GlassMaterialParsing)):
(TestWebKitAPI::TEST(AppleVisualEffect, GlassMaterialParsingWithoutUseSystemAppearance)):
(TestWebKitAPI::TEST(AppleVisualEffect, MediaControlsGlassMaterialParsing)):
(TestWebKitAPI::TEST(AppleVisualEffect, MediaControlsGlassMaterialParsingWithoutUseSystemAppearance)):
(TestWebKitAPI::TEST(AppleVisualEffect, MediaControlsSubduedGlassMaterialParsing)):
(TestWebKitAPI::TEST(AppleVisualEffect, MediaControlsSubduedGlassMaterialParsingWithoutUseSystemAppearance)):
(TestWebKitAPI::TEST(AppleVisualEffect, SubduedGlassMaterialParsing)):
(TestWebKitAPI::TEST(AppleVisualEffect, SubduedGlassMaterialParsingWithoutUseSystemAppearance)):
(TestWebKitAPI::TEST(AppleVisualEffect, NoCrashWhenRemovingLayers)):

Canonical link: https://commits.webkit.org/296094@main
@webkit-commit-queue
Copy link
Copy Markdown
Collaborator

Committed 296094@main (66fc5e1): https://commits.webkit.org/296094@main

Reviewed commits have been landed. Closing PR #46587 and removing active labels.

@webkit-commit-queue webkit-commit-queue removed the unsafe-merge-queue Applied to send a pull request to merge-queue, but skip building and testing label Jun 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

New Bugs Unclassified bugs are placed in this component until the correct component can be determined.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants