Back to Skiasharp

Version 4.151.0

documentation/docfx/releases/4.151.0.md

4.151.14.2 KB
Original Source
<!-- RELEASE-NOTES DATA (generated, do not edit) format:3 version:4.151.0 -->

Version 4.151.0

Skia m151 performance and platform · NuGet (prerelease)

API changes · SkiaSharp API diff · HarfBuzzSharp API diff

Highlights

SkiaSharp 4.151.0 updates to Skia m151 and eliminates allocations across several performance-critical hot paths. Color parsing, SKShaper glyph reads, and HarfBuzz shaping are reworked for zero-copy, allocation-free operation. A CPU raster regression introduced with the m151 sync is also corrected.

Breaking Changes

None in this preview line.

Engine

  • Skia updated to milestone m151 — Aligns the bundled renderer with Chrome milestone 151 and merges several rounds of upstream m151 bug fixes. (#4294, #4312, #4382, #4443)
  • CPU raster regression corrected — Restores SK_ENABLE_LEGACY_SHADERCONTEXT so CPU-rasterised surfaces produce correct output after the m151 sync. (#4428)

API Surface

  • SKColor gains ReadOnlySpan<char> hex-parse overloads — Adds ReadOnlySpan<char> overloads to SKColor hex parsing and optimises the internal path, removing a string allocation on every call. (#4345)
  • SKShaper glyph results read via zero-copy spans — GlyphRun data is now consumed through a Span<T> path rather than copying each element, reducing allocations during text layout. (#4388)
  • GRContextOptions unsafe modifier removed — Drops the unnecessary unsafe modifier from GRContextOptions, making it accessible from safe-only contexts without a compiler switch. (#3991)

Bug Fixes

  • Native resource leak in SKImage.FromEncodedData fixed — SKImage.FromEncodedData(SKData, SKRectI) now releases the underlying native handle when the subset crop fails, preventing a handle leak. (#3997)
  • Per-call allocation in SKFourByteTag.Parse eliminated — Removes the char[4] heap allocation made on every SKFourByteTag.Parse call by inlining the character construction. (#4396)

Platform

  • Emscripten 5.0.6 static libraries for .NET 11 WASM — Adds the Emscripten 5.0.6 prebuilt libraries needed to target .NET 11's WASM runtime, keeping SkiaSharp usable on the next .NET WASM host. — ❤️ @ramezgerges (#4459)

HarfBuzzSharp 14.2.1

Removes per-call heap allocations in HarfBuzzSharp.Buffer.AddUtf8 via a pooled UTF-8 encoder and in HarfBuzzSharp.Tag.Parse by inlining the char array construction, making shaping hot paths allocation-free.

Community Contributors ❤️

Thank you to everyone who contributed to this release!

ContributorContributions
@ramezgergesAdded Emscripten 5.0.6 static libraries for .NET 11 WASM, fixed the SK_BUILD_FOR_WASM redefinition in the Skia submodule, and built the cross-backend golden-image visual regression test harness (#3788, #4340, #4459)

Preview 2 (July 14, 2026)

Preview 2 landed the allocation-free SKShaper span path, the ReadOnlySpan<char> SKColor overloads, the GRContextOptions unsafe removal, HarfBuzz hot-path allocation fixes, and a batch of upstream m151 engine bug fixes.

Full changelog

Preview 1 (July 2, 2026)

Preview 1 opened the 4.151 line with the Skia m151 engine update and a fix to remove the SK_BUILD_FOR_WASM redefinition warning from WASM builds.

Full changelog