Skip to content

2.0 polish: extensible registrations, IByteSource in Abstractions, public API baseline - #3

Merged
sdcb merged 5 commits into
mainfrom
v2.0-polish
Nov 4, 2026
Merged

sdcb merged 5 commits into
mainfrom
v2.0-polish

Conversation

@sdcb

@sdcb sdcb commented Nov 4, 2026

Copy link
Copy Markdown
Owner

Pre-release polish of the 2.0 API (items 1–6 of the Abstractions review). Details in each commit.

🤖 Generated with Claude Code

sdcb and others added 3 commits November 4, 2026 19:16
…C profile

ImageDecoderRegistration, ImageEncoderRegistration and ImageMetadata take their
members as init properties (required where the facade needs them) instead of
positional constructors, so 2.x can add members without breaking compiled callers.
ImageMetadata is a record: change one block with `with`.

IDecodedImage.IccProfile and RasterImage's iccProfile parameter are gone; the
profile is Metadata.Icc. The facade's Register checks the planar delegate pair.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…n namespace

IByteSource / ByteSource move from the facade to Abstractions (namespace
Sdcb.SimdCodecs.Abstractions), so a codec can take one in 2.x without a breaking move.

ImageDecoderFallback, BufferedEncoderSession / BufferedFrame / EncoderFormats and
DecodeOptions.Validate / Apply (now C# 14 extension members, call sites unchanged)
move to Sdcb.SimdCodecs.Abstractions.CodecSupport: codec authors import it,
consumers no longer see them.

ImageDecoder.Metadata is read from the file once per session instead of on every get.

Docs: api-design (compatibility section), migration guide, known-gaps.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Microsoft.CodeAnalysis.PublicApiAnalyzers 5.6.0 on every project under src/:
PublicAPI.Shipped.txt records the 2.0 surface (with nullability), and an API change
that is not written into PublicAPI.Unshipped.txt fails the build (RS0016 / RS0017 as
errors, .editorconfig). Checked by adding an undeclared member: RS0016.

The analyzer's overload-shape rules RS0026 / RS0027 are off: the codecs deliberately
pair byte[] and ReadOnlySpan<byte> overloads with the same optional parameters.

AGENTS.md and api-design.md state the rule.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@sdcb
sdcb marked this pull request as ready for review November 4, 2026 11:33
sdcb and others added 2 commits November 4, 2026 19:39
…stay out of jit.txt

A NuGet advisory published 2026-11-03 (GHSA-p3jp-9v83-76w9, Microsoft.DotNet.ILCompiler
10.0.13) makes restore print NU1903 to stdout; `dotnet run` captured it into jit.txt,
which then differed from the AOT binary's output. The pixel digests were identical.
The WebAssembly smoke script already builds first.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
All packages ship together, so a breaking change is allowed when it is worth it:
write it into PublicAPI.Unshipped.txt and name it in the release notes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@sdcb
sdcb merged commit ad3dd5e into main Nov 4, 2026
7 checks passed
@sdcb
sdcb deleted the v2.0-polish branch November 4, 2026 12:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant