RecursiveAI.OneAudio.Devices 1.2.0

There is a newer version of this package available.
See the version list below for details.
dotnet add package RecursiveAI.OneAudio.Devices --version 1.2.0
                    
NuGet\Install-Package RecursiveAI.OneAudio.Devices -Version 1.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="RecursiveAI.OneAudio.Devices" Version="1.2.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="RecursiveAI.OneAudio.Devices" Version="1.2.0" />
                    
Directory.Packages.props
<PackageReference Include="RecursiveAI.OneAudio.Devices" />
                    
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 RecursiveAI.OneAudio.Devices --version 1.2.0
                    
#r "nuget: RecursiveAI.OneAudio.Devices, 1.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 RecursiveAI.OneAudio.Devices@1.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=RecursiveAI.OneAudio.Devices&version=1.2.0
                    
Install as a Cake Addin
#tool nuget:?package=RecursiveAI.OneAudio.Devices&version=1.2.0
                    
Install as a Cake Tool

RecursiveAI.OneAudio.Devices

Audio device playback and capture for RecursiveAI.OneAudio: WASAPI on Windows, Core Audio on macOS and iOS, ALSA on Linux, over the operating system's own libraries, with no dependencies beyond the .NET base class library.

using OneAudio;

using var mixer = Audio.CreateMixer();                 // 48 kHz stereo
using var output = Audio.Play(mixer);                  // default device, follows default changes
mixer.Play(Audio.Load("shot.ogg"));
Console.WriteLine(output.Counters);                    // frames written and played, peak, underruns, losses, reopens

The full device API is described in docs/api.md.

Apple notes

  • macOS: playback and capture on any Core Audio device, rate and channel conversion handled for you, and the stream follows default-device changes and removal. The system picks the hardware buffer size unless you set PeriodFrames or BufferFrames.
  • Microphone: if the user denied access, opening an input fails with a message saying so. A command-line program without an app bundle and a microphone usage description may be unable to ask and receive silence.
  • iOS: set DeviceStreamOptions.AppleSession to choose the audio-session category (Ambient by default). Interruptions pause the stream and resume it afterwards; the app needs a microphone usage description in its Info.plist to record. NativeAOT output exists for devices (ios-arm64); the simulator runs the Mono build.

Windows (WASAPI)

Shared mode (the default) converts any rate and channel count through the Windows mixer; its engine period is 10 ms by default (Microsoft's documented figure). ShareMode.Exclusive owns the device for lower latency, bounded by the driver's minimum period (a few milliseconds typically, as documented by Microsoft), but needs a format the hardware accepts directly: float32 or 32/24/16-bit integer at exactly your rate and channel count. When it cannot be granted the open is refused with a reason in LastError. A machine with no audio endpoint is the same as any missing device: the output runs silently at real-time pace and retries.

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on RecursiveAI.OneAudio.Devices:

Package Downloads
RecursiveAI.OneGame.Audio

Audio device output and the audio service that drives a mixer.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.2.1 0 10/27/2026
1.2.0 0 10/27/2026