pub struct AsioBackend { /* private fields */ }Expand description
ASIO host backend with provider-supplied deterministic driver data.
Implementations§
Source§impl AsioBackend
impl AsioBackend
Sourcepub fn new(drivers: Vec<AsioDriver>) -> Self
pub fn new(drivers: Vec<AsioDriver>) -> Self
Builds a backend over the provider-reported drivers, marking it as a
native (non-fake) backend and deriving its capabilities from the driver
set.
Sourcepub fn fake() -> Self
pub fn fake() -> Self
Builds an offline backend exposing the single SIM-ASIO driver, marked
as fake so it can run under CI without the ASIO SDK or audio hardware.
Sourcepub fn list_drivers(&self) -> &[AsioDriver]
pub fn list_drivers(&self) -> &[AsioDriver]
Returns the drivers this backend was constructed with.
Sourcepub fn sim_driver(&self) -> Option<&AsioDriver>
pub fn sim_driver(&self) -> Option<&AsioDriver>
Returns the bundled SIM-ASIO driver if it is present in the backend.
Sourcepub fn open_sim_driver(&self, capacity: usize) -> Result<HostOpenStream>
pub fn open_sim_driver(&self, capacity: usize) -> Result<HostOpenStream>
Opens a duplex stream on the bundled SIM-ASIO driver with a bounded
buffer of capacity packets.
Returns an error if the SIM-ASIO driver is not present in this backend.
Trait Implementations§
Source§impl Clone for AsioBackend
impl Clone for AsioBackend
Source§fn clone(&self) -> AsioBackend
fn clone(&self) -> AsioBackend
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for AsioBackend
impl Debug for AsioBackend
Source§impl Default for AsioBackend
impl Default for AsioBackend
Source§impl HostBackend for AsioBackend
impl HostBackend for AsioBackend
Source§fn info(&self) -> &HostBackendInfo
fn info(&self) -> &HostBackendInfo
Stable backend metadata.
Source§fn enumerate(&self) -> Result<HostDeviceInventory>
fn enumerate(&self) -> Result<HostDeviceInventory>
Enumerates available devices and ports without opening hardware streams.
Source§fn open(&self, request: HostStreamConfigRequest) -> Result<HostOpenStream>
fn open(&self, request: HostStreamConfigRequest) -> Result<HostOpenStream>
Opens a stream according to the requested host configuration.
Auto Trait Implementations§
impl Freeze for AsioBackend
impl RefUnwindSafe for AsioBackend
impl Send for AsioBackend
impl Sync for AsioBackend
impl Unpin for AsioBackend
impl UnsafeUnpin for AsioBackend
impl UnwindSafe for AsioBackend
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more