Repository navigation
Add Graphite views for .NET MAUI - #4739
mattleibow wants to merge 3 commits into
Conversation
Expose deferred canvases, Vulkan synchronization and texture-state primitives, and 64-bit-safe external handles independently of any view implementation.\n\nCo-authored-by: Copilot App <[email protected]>\nCopilot-Session: 00cda8ff-9603-406f-ae2e-45c70e39b3e7
Carve the reviewed native Graphite views package from the combined Graphite views work and add direct native Basic samples for Android, iOS, Mac Catalyst, macOS, and tvOS. Gate Android below API 24 and keep the sample render loops lifecycle-aware and failure-reporting. Related: #4721 Requires: #4729 Requires: mono/skia#345 Co-authored-by: Copilot App <[email protected]> Copilot-Session: dd83f08e-1222-4b30-b315-1a5c2103463a
Layer a backend-neutral MAUI control over the native Graphite views and add the multi-recorder MAUI sample plus lifecycle/integration coverage.\n\nCo-authored-by: Copilot App <[email protected]>\nCopilot-Session: 00cda8ff-9603-406f-ae2e-45c70e39b3e7
📦 Try the packages from this PRWarning Do not run these scripts without first reviewing the code in this PR. Step 1 — Download the packages bash / macOS / Linux: curl -fsSL https://raw.githubusercontent.com/mono/SkiaSharp/main/scripts/get-skiasharp-pr.sh | bash -s -- 4739PowerShell / Windows: iex "& { $(irm https://raw.githubusercontent.com/mono/SkiaSharp/main/scripts/get-skiasharp-pr.ps1) } 4739"Step 2 — Add the local NuGet source dotnet nuget add source ~/.skiasharp/hives/pr-4739/packages --name skiasharp-pr-4739More options
Or download manually from Azure Pipelines — look for the Remove the source when you're done: dotnet nuget remove source skiasharp-pr-4739 |
|
📖 Documentation Preview The documentation for this PR has been deployed and is available at: 🔗 View Staging Site This preview will be updated automatically when you push new commits to this PR. This comment is automatically updated by the documentation staging workflow. |
📊 SkiaSharp benchmarks — PR #4739⭐ this PR (full source build) vs 🌙 nightly · Linux · Windows · macOS
Highlights⏱️ Time — 🔴 44 slower · 🟢 43 faster
📦 Allocations — 🔴 1 more alloc · 🟢 0 less alloc
Full per-OS benchmark deltasLinux⏱️ Time (vs 🌙 nightly
📦 Allocations (vs 🌙 nightly
Windows⏱️ Time (vs 🌙 nightly
macOS⏱️ Time (vs 🌙 nightly
|
|
Superseded by the staged split. The Apple-native foundation is now isolated in #4745, while #4729 and mono/skia#345 continue in parallel. Once those prerequisites land, Apple MAUI and Android native views will proceed as separate parallel PRs; Android MAUI will be the final layer that enables the existing Graphite sample page on Android API 24+. The runtime screenshots and exact cumulative source commit remain available here for carving and validating the later MAUI layers. |
Description
Adds the backend-neutral
SKGraphiteViewfor .NET MAUI over the native Apple/Android controls from #4734. This top layer contains only MAUI controls/handlers, touch/lifecycle plumbing, the MAUI multi-recorder sample, and MAUI tests.The sample demonstrates Graphite’s record/snap/insert/submit model without claiming unmeasured Ganesh speedups: a cached background
Recordingis replayed while two thread-affine recorders build animated layers concurrently.This PR is commit-stacked on the lower layers but intentionally targets
mainso its full CI can run immediately. Merge/review order is #4729, then #4734, then this PR.Related issues
Fixes #4721
Related to #3962
Required skia PR
Transitively requires mono/skia#345
Required lower SkiaSharp PRs
Areas affected
binding/)externals/skia/src/c,include/c)Changes
Public API
Behavior
HasRenderLoop, invalidation, pixel scaling, touch, detach/reconnect, context changes, and render failures follow existing MAUI view conventions.Testing
SkiaSharp.Views.Graphite4.152.0.MAUI Graphite sample screenshots
Checklist
Changesabove lists all public API and behavioral changes (or "None.")mono/skiaPR linked above and bindings regenerated in lower PR Add Graphite presentation interop #4729