Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions src/Sendspin.SDK/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ A cross-platform .NET SDK for the Sendspin synchronized multi-room audio protoco
- **Server Discovery**: mDNS-based automatic server discovery
- **Audio Decoding**: Built-in PCM, FLAC, and Opus codec support
- **Cross-Platform**: Works on Windows, Linux, and macOS (.NET 8.0 / .NET 10.0)
- **NativeAOT & Trimming**: Fully compatible with `PublishAot` and IL trimming for single-file native executables with no .NET runtime dependency
- **Audio Device Switching**: Hot-switch audio output devices without interrupting playback

## Installation
Expand Down Expand Up @@ -252,8 +253,41 @@ var capabilities = new ClientCapabilities

All fields are optional and omitted from the protocol if null.

## NativeAOT Support

Since v7.0.0, the SDK is fully compatible with [NativeAOT deployment](https://learn.microsoft.com/en-us/dotnet/core/deploying/native-aot/) and IL trimming. This means you can publish your Sendspin player as a single native executable with no .NET runtime dependency — ideal for embedded devices, containers, or minimal Linux installations.

```xml
<PropertyGroup>
<PublishAot>true</PublishAot>
</PropertyGroup>
```

```bash
dotnet publish -c Release -r linux-x64
# Produces a single native binary (~15-25MB depending on dependencies)
```

**How it works**: The SDK uses source-generated `System.Text.Json` serialization (no runtime reflection) and built-in .NET WebSocket APIs. All public types are annotated with `IsAotCompatible` and `IsTrimmable` to ensure the .NET build analyzers catch any regressions.

**Your code**: If your `IAudioPlayer` implementation also avoids reflection, the entire stack will be AOT-safe. Most audio libraries (SDL2, OpenAL, PipeWire bindings) work fine with NativeAOT.

## Migration Guide

### Upgrading to v7.0.0

**Breaking change**: `SendspinListener.ServerConnected` event parameter type changed.

```csharp
// Before (v6.x):
listener.ServerConnected += (sender, fleckConnection) => { /* Fleck.IWebSocketConnection */ };

// After (v7.0+):
listener.ServerConnected += (sender, wsConnection) => { /* WebSocketClientConnection */ };
```

No changes needed if you only use `SendspinHostService` or `SendspinClientService` (most consumers).

### Upgrading to v5.0.0

**Breaking change**: Sync correction is now external. The SDK reports error; you apply correction.
Expand Down
7 changes: 6 additions & 1 deletion src/Sendspin.SDK/Sendspin.SDK.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

<!-- NuGet Package Metadata -->
<PackageId>Sendspin.SDK</PackageId>
<Version>7.1.0</Version>
<Version>7.1.1</Version>
<Authors>Sendspin Contributors</Authors>
<Company>Sendspin</Company>
<Product>Sendspin SDK</Product>
Expand All @@ -20,6 +20,11 @@
<PackageLicenseExpression>MIT</PackageLicenseExpression>
<PackageReadmeFile>README.md</PackageReadmeFile>
<PackageReleaseNotes>
v7.1.1 - Documentation:
- Added NativeAOT support section to README with PublishAot usage and guidance
- Added v7.0.0 migration guide for SendspinListener.ServerConnected breaking change
- Listed NativeAOT &amp; trimming compatibility in Features section

v7.1.0 - Protocol Compliance (aiosendspin audit):

New Features:
Expand Down
Loading