Repository navigation
perf(images): use mipmapping when downscaling instead of bicubic or Lanczos samplers - #20663
Conversation
|
🤖 Your WebAssembly Skia Sample App stage site is ready! Visit it here: https://unowasmprstaging.z20.web.core.windows.net/pr-20663/wasm-skia-net9/index.html |
|
🤖 Your Docs stage site is ready! Visit it here: https://unodocsprstaging.z13.web.core.windows.net/pr-20663/docs/index.html |
|
🤖 Your Docs stage site is ready! Visit it here: https://unodocsprstaging.z13.web.core.windows.net/pr-20663/docs/index.html |
|
🤖 Your WebAssembly Skia Sample App stage site is ready! Visit it here: https://unowasmprstaging.z20.web.core.windows.net/pr-20663/wasm-skia-net9/index.html |
|
|
There was a problem hiding this comment.
Pull Request Overview
This PR improves image downscaling performance by switching to mipmapping instead of using bicubic or Lanczos samplers. Key changes include adjusting offset values in image brush tests, replacing custom downsampling shader logic with SKSamplingOptions that leverage mipmapping, and adding new performance tests to assess the improvements.
Reviewed Changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| src/Uno.UI.RuntimeTests/Tests/Windows_UI_Xaml_Media/Given_ImageBrush.cs | Adjusted border offset logic for APPLE_UIKIT and SKIA platforms |
| src/Uno.UI.Composition/Composition/CompositionSurfaceBrush.skia.cs | Updated downsampling path to use mipmapping instead of a custom shader implementation |
| src/SamplesApp/UITests.Shared/Windows_UI_Xaml/Performance/Performance_ManyImages.xaml.cs | Added performance test for rendering many images |
| src/SamplesApp/UITests.Shared/Windows_UI_Xaml/Performance/Performance_ManyImages.xaml | New XAML page for performance testing |
| src/SamplesApp/UITests.Shared/UITests.Shared.projitems | Included new files in the project build |
Comments suppressed due to low confidence (1)
src/Uno.UI.Composition/Composition/CompositionSurfaceBrush.skia.cs:116
- The condition for choosing the downsampling path has changed from comparing sigma values to a direct comparison of image and bounds dimensions; please confirm that this new logic aligns with the intended quality and performance goals.
if (scs.Image.Width < bounds.Width || scs.Image.Height < bounds.Height)
|
🤖 Your WebAssembly Skia Sample App stage site is ready! Visit it here: https://unowasmprstaging.z20.web.core.windows.net/pr-20663/wasm-skia-net9/index.html |
|
🤖 Your Docs stage site is ready! Visit it here: https://unodocsprstaging.z13.web.core.windows.net/pr-20663/docs/index.html |
|
🤖 Your WebAssembly Skia Sample App stage site is ready! Visit it here: https://unowasmprstaging.z20.web.core.windows.net/pr-20663/wasm-skia-net9/index.html |
|
🤖 Your Docs stage site is ready! Visit it here: https://unodocsprstaging.z13.web.core.windows.net/pr-20663/docs/index.html |
|
|
|
🤖 Your WebAssembly Skia Sample App stage site is ready! Visit it here: https://unowasmprstaging.z20.web.core.windows.net/pr-20663/wasm-skia-net9/index.html |
|
🤖 Your Docs stage site is ready! Visit it here: https://unodocsprstaging.z13.web.core.windows.net/pr-20663/docs/index.html |
|
|
GitHub Issue (If applicable): closes #17325
PR Type
What kind of change does this PR introduce?
What is the current behavior?
What is the new behavior?
PR Checklist
Please check if your PR fulfills the following requirements:
Screenshots Compare Test Runresults.Other information
Internal Issue (If applicable):