Expand description
Modeled ALSA stream-host adapter (in-process simulation).
Modeled tier, no native I/O. This crate is a pure-Rust, in-process MODEL of
an ALSA backend, not a binding to libasound. The workspace forbids
unsafe and the crate carries no -sys/FFI dependency, so it performs no
real Linux PCM I/O – it serves deterministic, provider-reported fake
devices. The modeled tier is flagged by the default-on model feature; a
native provider would live behind a separate FFI binding outside this repo.
This crate keeps validation independent of an ALSA development package or
local sound hardware. It models provider-reported ALSA PCM devices, supports
default, hw:*, and plughw:* names, exposes host inventory/open plans,
bridges playback callbacks into ProcessBlock, and records capture buffers
as PCM stream packets. A future native provider can populate the same model
from snd_pcm_* enumeration. ALSA sequencer MIDI is intentionally left as a
follow-up for a MIDI-specific adapter so this crate remains focused on PCM.
Structs§
- Alsa
Backend - ALSA host backend with provider-supplied deterministic PCM devices.
- Alsa
Capture Bridge - Converts ALSA capture buffers into PCM stream packets.
- AlsaLib
- Host-registered lib exporting the ALSA stream-host cards, built on the shared
SurfacePackLibsubstrate. - Alsa
PcmDevice - SIM-visible ALSA PCM device metadata.
- Alsa
PcmName - Parsed ALSA PCM name accepted by this adapter.
- Alsa
Playback Bridge - Drives an audio graph processor from an ALSA playback callback.
Enums§
- Alsa
PcmName Kind - Supported ALSA PCM name family.
Functions§
- alsa_
backend_ symbol - Returns the backend identity symbol
stream/host:alsa. - alsa_
transport_ symbol - Returns the transport identity symbol
stream/transport:alsa. - default_
modeled_ alsa_ site - Builds the default modeled ALSA playback site.
- install_
stream_ alsa_ lib - Installs the
AlsaLibintocx, idempotently.