SimpleAudioPlayer.Native 2.2.0

There is a newer version of this package available.
See the version list below for details.
dotnet add package SimpleAudioPlayer.Native --version 2.2.0
                    
NuGet\Install-Package SimpleAudioPlayer.Native -Version 2.2.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="SimpleAudioPlayer.Native" Version="2.2.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="SimpleAudioPlayer.Native" Version="2.2.0" />
                    
Directory.Packages.props
<PackageReference Include="SimpleAudioPlayer.Native" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add SimpleAudioPlayer.Native --version 2.2.0
                    
#r "nuget: SimpleAudioPlayer.Native, 2.2.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package SimpleAudioPlayer.Native@2.2.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=SimpleAudioPlayer.Native&version=2.2.0
                    
Install as a Cake Addin
#tool nuget:?package=SimpleAudioPlayer.Native&version=2.2.0
                    
Install as a Cake Tool

SimpleAudioPlayer Native Library

中文版本

Introduction

This repository contains the native library for the SimpleAudioPlayer project. Built on miniaudio framework and FFmpeg multimedia decoding library, it provides cross-platform audio decoding and playback capabilities.

Key Features

  • FFmpeg-based audio decoding with common format support
  • Cross-platform audio backend via miniaudio
  • Stream playback and audio resampling support
  • Native recording support for PCM, WAV, AAC, and M4A outputs
  • Decoder callback support for stream length and seek capability
  • Propagates stream and decoder failures separately from normal EOF
  • Clean C/C++ API interface

Version 2.2

Version 2.2 adds configurable output-device APIs and maps playback usage and content type to supported platform audio backends.

Version 2.0 updated the native callback contract used by SimpleAudioPlayer. It added explicit stream length and seek capability callbacks, preserves decode failure results, and reports I/O failures separately from normal end-of-stream completion.

Use SimpleAudioPlayer.Native 2.2.0 with SimpleAudioPlayer 2.2.0. Older native packages do not contain the extended output-device entry point.

Output Device Configuration

audio_init_device_ex accepts a versioned, size-tagged AudioDeviceConfig for sample rate, channels, buffer periods, performance preference, sharing mode, and cross-platform playback intent. Android maps the intent to AAudio usage/contentType and the OpenSL ES stream type. The existing audio_init_device entry point remains available with its original defaults.

Dependencies

  • FFmpeg (version >= 6.1)
  • miniaudio (version >= 0.11)
  • C++17 compatible compiler

Building

Refer to GitHub Actions CI.yml

License Information

This project is licensed under LGPL-3.0. Key requirements:

  1. Dynamic linking allows proprietary use
  2. Modifications must be open-sourced
  3. Original copyright notices must be preserved

Acknowledgments

This project stands on the shoulders of:

License

license

There are no supported framework assets in this package.

Learn more about Target Frameworks and .NET Standard.

This package has no dependencies.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on SimpleAudioPlayer.Native:

Package Downloads
SimpleAudioPlayer

Simple Audio Player with miniaudio and ffmpeg

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
2.3.1 199 7/25/2026
2.3.0 133 7/25/2026
2.2.0 154 7/22/2026
2.1.1 132 6/24/2026
2.1.0 137 6/23/2026
2.0.0 146 6/11/2026
1.8.3 128 6/11/2026
1.8.2 191 5/25/2026
1.8.1 151 4/27/2026
1.8.0 500 4/16/2025
1.7.0 357 4/15/2025
1.6.0 265 3/27/2025
1.5.0 268 3/13/2025
1.4.0 308 3/12/2025
1.3.0 281 3/11/2025
1.2.0 336 3/9/2025
1.1.0 355 3/7/2025
1.0.0 350 3/6/2025