SIPSorceryMedia.Abstractions 10.0.8

SIPSorceryMedia.Abstractions

NuGet NuGet downloads

Shared interfaces, enums, and helper types that connect the SIPSorcery real-time communications library to media-device and codec implementations.

This package is a small dependency-free abstraction layer. You normally don't reference it directly -- it comes in transitively via the main SIPSorcery package and via media end-point implementations such as SIPSorceryMedia.Windows or SIPSorceryMedia.FFmpeg. You only reference it explicitly when you're writing your own media end-point or codec wrapper.

Installation

dotnet add package SIPSorceryMedia.Abstractions

What is in here

The package defines the contracts that every audio / video source, sink and codec implements so the SIPSorcery library can interoperate with them generically.

Codec interfaces

Interface Implement when... Reference implementation
IAudioEncoder You provide audio encoding / decoding (G711, G722, G729, Opus, ...) AudioEncoder in the main SIPSorcery package
IVideoEncoder You provide video encoding / decoding (VP8, H.264, ...) Vp8NetVideoEncoder (pure C#); FFmpeg wrappers in SIPSorceryMedia.FFmpeg

Audio source / sink interfaces

Interface Implement when... Reference implementation
IAudioSource Your class is a source of raw audio samples (microphone, file player, signal generator) WindowsAudioEndPoint
IAudioSink Your class consumes raw audio samples (speaker, recorder, RTP transmit) WindowsAudioEndPoint
IAudioEndPoint Your class is both a source and a sink (full-duplex device) WindowsAudioEndPoint, FFmpegAudioEndPoint

Video source / sink interfaces

Interface Implement when... Reference implementation
IVideoSource Your class is a source of raw video frames (webcam, file player, test pattern) WindowsVideoEndPoint; VideoTestPatternSource in the main SIPSorcery package
IVideoSink Your class consumes raw video frames (display, recorder) WindowsVideoEndPoint, FFmpegVideoEndPoint
IVideoEndPoint Both a source and a sink for video various

Common types and helpers

The package also contains shared types referenced from across the ecosystem:

  • AudioFormat, VideoFormat -- describe a codec / sample-rate / channel-layout combination negotiated over SDP.
  • AudioSamplingRatesEnum, VideoPixelFormatsEnum, VideoCodecsEnum, AudioCodecsEnum.
  • RawImage -- header + pinned byte buffer wrapper used to pass decoded video frames between encoders and sinks without copying.
  • PixelConverter -- conversion helpers between common pixel formats (I420, NV12, BGR, RGB, YUV).

Versioning and compatibility

SIPSorceryMedia.Abstractions shares a major version line with the main SIPSorcery package. A binary-incompatible change to any of the interfaces would land as a major version bump on both packages together; minor versions add new interfaces or new types but never modify existing ones in breaking ways.

  • SIPSorcery -- the main real-time communications library that consumes these abstractions.
  • SIPSorceryMedia.Windows -- Windows-specific implementations of the audio / video end-point interfaces.
  • SIPSorceryMedia.FFmpeg -- cross-platform implementations using FFmpeg native libraries.
  • SIPSorcery.VP8 -- pure C# IVideoEncoder implementation for VP8.

License

BSD 3-Clause License. See LICENSE at the repo root.

No packages depend on SIPSorceryMedia.Abstractions.

-v10.0.8: Full library release. -v10.0.7: Updated for main sipsorcery library release. -v10.0.6: Updated for main sipsorcery library release. -v10.0.5: Updated for main sipsorcery library release. -v8.0.12: Added IAudioEndPoint and GotEncodedMediaFrame to IAudioSink. -v8.0.10: Change to text encoder interface. -v8.0.7: New sampling frequencies and all sipsorcery packages release. -v1.2.1: Expose LogFactory signature to generate generic logger. Added .net8.0 target -v1.2.0: Add RawImage and new events / methods to avoid the use of byte[] to improve performance. -v1.1.0: Stable release. -v1.0.4-pre: Changed IAudioEncoder and IVideoEncoder to use SupportedFormats property instead of IsSupported method. -v1.0.3-pre: Added video format to IVideoSink.GotVideoFrame. Removed 'V1' from namespace, the versioning mechanism is not going to be suitable for such a formative API. -v1.0.2-pre: Improved pixel conversion routines to take a stride parameter and handle uneven dimensions. -1.0.1: Added NV12 as a pixel format option. -1.0.0: Initial stable release

Version Downloads Last updated
10.0.8 1 05/29/2026
10.0.7 1 05/29/2026
10.0.6 1 05/29/2026
10.0.5 1 05/29/2026
8.0.12 7 09/16/2025
8.0.10 6 09/16/2025
8.0.7 9 09/15/2025
1.2.1 7 09/16/2025
1.2.0 6 09/16/2025
1.1.0 7 09/16/2025
1.0.4-pre 8 09/16/2025
1.0.3-pre 8 09/16/2025
1.0.2-pre 8 09/16/2025
1.0.1 7 09/16/2025
1.0.0 7 09/16/2025
0.0.22-pre 6 09/16/2025
0.0.20-pre 6 09/16/2025
0.0.19-pre 6 09/16/2025
0.0.18-pre 6 09/16/2025
0.0.17-pre 6 09/16/2025
0.0.16-pre 6 09/16/2025
0.0.15-pre 7 09/16/2025
0.0.14-pre 6 09/16/2025
0.0.12-pre 6 09/16/2025
0.0.11-pre 6 09/16/2025
0.0.10-pre 6 09/16/2025
0.0.9-pre 8 09/16/2025
0.0.7-pre 8 09/16/2025
0.0.6-pre 8 09/16/2025
0.0.5-pre 9 09/16/2025
0.0.4-pre 8 09/16/2025
0.0.3-pre 9 09/16/2025
0.0.2-pre 8 09/16/2025
0.0.1-pre 8 09/16/2025